Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ jobs:
- "8.2"
- "8.3"
- "8.4"
- "8.5"

compiler:
- default
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Smarty is a template engine for PHP, facilitating the separation of presentation
Read the [documentation](https://smarty-php.github.io/smarty/) to find out how to use it.

## Requirements
Smarty can be run with PHP 7.1 to PHP 8.4.
Smarty can be run with PHP 7.1 to PHP 8.5.

## Installation
Smarty versions 3.1.11 or later can be installed with [Composer](https://getcomposer.org/).
Expand Down
1 change: 1 addition & 0 deletions changelog/1184.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- PHP8.5 support [#1184](https://github.com/smarty-php/smarty/issues/1184)
5 changes: 5 additions & 0 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,8 @@ services:
service: base
build:
dockerfile: ./utilities/testrunners/php84/Dockerfile
php85:
extends:
service: base
build:
dockerfile: ./utilities/testrunners/php85/Dockerfile
2 changes: 1 addition & 1 deletion docs/getting-started.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Getting started

## Requirements
Smarty can be run with PHP 7.1 to PHP 8.4.
Smarty can be run with PHP 7.1 to PHP 8.5.

## Installation
Smarty can be installed with [Composer](https://getcomposer.org/).
Expand Down
5 changes: 3 additions & 2 deletions run-tests-for-all-php-versions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
# - ./run-tests-for-all-php-versions.sh --group 20221124
# - ./run-tests-for-all-php-versions.sh --exclude-group slow

COMPOSE_CMD="mutagen-compose"
COMPOSE_CMD="docker-compose"

$COMPOSE_CMD run --rm php71 ./run-tests.sh $@ && \
$COMPOSE_CMD run --rm php72 ./run-tests.sh $@ && \
Expand All @@ -15,4 +15,5 @@ $COMPOSE_CMD run --rm php80 ./run-tests.sh $@ && \
$COMPOSE_CMD run --rm php81 ./run-tests.sh $@ && \
$COMPOSE_CMD run --rm php82 ./run-tests.sh $@ && \
$COMPOSE_CMD run --rm php83 ./run-tests.sh $@ && \
$COMPOSE_CMD run --rm php84 ./run-tests.sh $@
$COMPOSE_CMD run --rm php84 ./run-tests.sh $@ && \
$COMPOSE_CMD run --rm php85 ./run-tests.sh $@
Original file line number Diff line number Diff line change
Expand Up @@ -1381,7 +1381,7 @@ public function testBlockWithAssign() {
public function testEscaping()
{
$this->expectException(SmartyException::class);
$this->expectExceptionMessageRegExp('/Unable to load.*/');
$this->expectExceptionMessageMatches('/Unable to load.*/');
$this->assertEquals('hello world', $this->smarty->fetch('escaping.tpl'));
}

Expand All @@ -1391,7 +1391,7 @@ public function testEscaping()
public function testEscaping2()
{
$this->expectException(SmartyException::class);
$this->expectExceptionMessageRegExp('/Unable to load.*/');
$this->expectExceptionMessageMatches('/Unable to load.*/');
$this->assertEquals('hello world', $this->smarty->fetch('escaping2.tpl'));
}

Expand All @@ -1401,7 +1401,7 @@ public function testEscaping2()
public function testEscaping3()
{
$this->expectException(SmartyException::class);
$this->expectExceptionMessageRegExp('/Unable to load.*/');
$this->expectExceptionMessageMatches('/Unable to load.*/');
$this->assertEquals('hello world', $this->smarty->fetch('escaping3.tpl'));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ public function testSpacing_001V3($merge, $caching, $text)
public function testIncludeFilenameEscaping()
{
$this->expectException(SmartyException::class);
$this->expectExceptionMessageRegExp('/Unable to load.*/');
$this->expectExceptionMessageMatches('/Unable to load.*/');
$tpl = $this->smarty->createTemplate('test_include_security.tpl');
$content = $this->smarty->fetch($tpl);
$this->assertEquals("hello world", $content);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function testextends419()
public function testextendsSecurity()
{
$this->expectException(SmartyException::class);
$this->expectExceptionMessageRegExp('/Unable to load.*/');
$this->expectExceptionMessageMatches('/Unable to load.*/');
$this->assertEquals('child', $this->smarty->fetch('string:{include "001_parent.tpl\', var_dump(shell_exec(\'ls\')), 1, 2, 3, 4, 5, 6);}}?>"}'));
}

Expand Down
10 changes: 10 additions & 0 deletions utilities/testrunners/php85/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
FROM php:8.5-rc-cli-bullseye

## Basic utilities
RUN apt-get update -yqq && apt-get install -y curl apt-utils git zip unzip

## Composer
COPY ./utilities/testrunners/shared/install-composer.sh /root/install-composer.sh
WORKDIR /root
RUN sh ./install-composer.sh
RUN mv ./composer.phar /usr/local/bin/composer
Loading