Skip to content

Commit

Permalink
Merge pull request #1459 from garak/fix-tests
Browse files Browse the repository at this point in the history
💚 fix tests
  • Loading branch information
garak authored Jul 7, 2024
2 parents 3b1d60c + ed76a9d commit 59c8a8a
Show file tree
Hide file tree
Showing 9 changed files with 16 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ jobs:
with_oneupbundle: false
max_deprecations: 0
- php: '8.3'
symfony: '7.0.*'
symfony: '7.1.*'
dependencies: highest
with_imagine: false
with_oneupbundle: false
Expand Down
4 changes: 2 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@
"require": {
"php": "^8.1",
"ext-simplexml": "*",
"doctrine/persistence": "^3",
"doctrine/persistence": "^3.0",
"jms/metadata": "^2.4",
"symfony/config": "^5.4 || ^6.0 || ^7.0",
"symfony/console": "^5.4 || ^6.0 || ^7.0",
"symfony/dependency-injection": "^5.4 || ^6.0 || ^7.0",
"symfony/event-dispatcher-contracts": "^3.1",
"symfony/http-foundation": "^5.4 || ^6.0 || ^7.0",
"symfony/http-kernel": "^5.4 || ^6.0 || ^7.0",
"symfony/http-kernel": "^5.4 || ^6.0, !=6.4.9 || ^7.0, !=7.1.2",
"symfony/mime": "^5.4 || ^6.0 || ^7.0",
"symfony/property-access": "^5.4 || ^6.0 || ^7.0",
"symfony/string": "^5.4 || ^6.0 || ^7.0"
Expand Down
6 changes: 5 additions & 1 deletion docker/Dockerfile81
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,11 @@ WORKDIR /srv/vich-uploader
COPY . ./

RUN set -eux; \
composer install --prefer-dist --ignore-platform-reqs; \
composer global config --no-plugins allow-plugins.symfony/flex true; \
composer global require --no-interaction --no-progress symfony/flex:^2.2; \
composer config extra.symfony.require "^6.4"; \
composer require --no-update doctrine/annotations:^1.14; \
composer update --prefer-dist --ignore-platform-reqs; \
composer clear-cache

CMD ["/init"]
1 change: 1 addition & 0 deletions docker/Dockerfile82
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ WORKDIR /srv/vich-uploader
COPY . ./

RUN set -eux; \
composer require --no-update doctrine/annotations:^1.14; \
composer update --prefer-dist --ignore-platform-reqs; \
composer clear-cache

Expand Down
1 change: 1 addition & 0 deletions docker/Dockerfile83
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ WORKDIR /srv/vich-uploader
COPY . ./

RUN set -eux; \
composer require --no-update doctrine/annotations:^1.14; \
composer update --prefer-dist --ignore-platform-reqs; \
composer clear-cache

Expand Down
10 changes: 2 additions & 8 deletions src/Metadata/ClassMetadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,12 @@ final class ClassMetadata extends BaseClassMetadata

public function serialize(): string
{
return \serialize([
$this->fields,
parent::serialize(),
]);
return \serialize([$this->fields, parent::serialize()]);
}

public function unserialize($str): void
{
[
$this->fields,
$parentStr
] = \unserialize($str);
[$this->fields, $parentStr] = \unserialize($str);

parent::unserialize($parentStr);
}
Expand Down
2 changes: 2 additions & 0 deletions tests/DummyFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ class DummyFile
{
/**
* @ORM\Id
*
* @ORM\Column(type="integer")
*
* @ORM\GeneratedValue(strategy="AUTO")
*
* @var int
Expand Down
1 change: 1 addition & 0 deletions tests/DummyImageFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

/**
* @ORM\Entity
*
* @Vich\Uploadable
*/
class DummyImageFile
Expand Down
2 changes: 1 addition & 1 deletion tests/VichUploaderBundleTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public function testFlysystemOfficialKernel(): void
public function testFlysystemOneUpKernel(): void
{
if (!\class_exists(OneupFlysystemBundle::class)) {
$this->markTestSkipped('OneupFlysystemBundle supports only PHP > 7.4');
$this->markTestSkipped('OneupFlysystemBundle not installed');
}

$kernel = new FlysystemOneUpAppKernel('test', true);
Expand Down

0 comments on commit 59c8a8a

Please sign in to comment.