Skip to content

Commit

Permalink
bump: all the things (#144)
Browse files Browse the repository at this point in the history
  • Loading branch information
dkarlovi authored Sep 7, 2023
1 parent e25b4c2 commit e34c9b4
Show file tree
Hide file tree
Showing 12 changed files with 22 additions and 24 deletions.
5 changes: 1 addition & 4 deletions psalm.baseline.xml
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<files psalm-version="5.8.0@9cf4f60a333f779ad3bc704a555920e81d4fdcda">
<files psalm-version="5.14.1@b9d355e0829c397b9b3b47d0c0ed042a8a70284d">
<file src="tests/functional/MakefileTestCase.php">
<LessSpecificReturnType>
<code><![CDATA[list<string>]]></code>
</LessSpecificReturnType>
<MixedArgument>
<code>$command</code>
<code>$dir</code>
Expand Down
2 changes: 1 addition & 1 deletion psalm.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
findUnusedPsalmSuppress="true"
findUnusedVariablesAndParams="true"
limitMethodComplexity="true"
restrictReturnTypes="true"
restrictReturnTypes="false"
strictBinaryOperands="true">
<projectFiles>
<directory name="./"/>
Expand Down
2 changes: 1 addition & 1 deletion resources/Lighthouse/common.mk
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
LIGHTHOUSE_DOCKER_IMAGE ?= cypress/browsers:node-18.16.0-chrome-112.0.5615.121-1-ff-112.0.1-edge-112.0.1722.48-1
LIGHTHOUSE_DOCKER_IMAGE ?= cypress/browsers:node-20.5.0-chrome-114.0.5735.133-1-ff-114.0.2-edge-114.0.1823.51-1
LIGHTHOUSE_DOCKER_COMMAND ?= docker run --init --interactive ${DOCKER_TTY} --rm --env HOME=/tmp ${DOCKER_USER} --volume "${DOCKER_CWD}:/public" --workdir "/public" ${LIGHTHOUSE_DOCKER_IMAGE}

analyze/lighthouse: ## Analyze built files using Lighthouse
Expand Down
2 changes: 1 addition & 1 deletion resources/PHP/common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ PHP_VERSION=8.2
endif

ifndef PHPQA_DOCKER_IMAGE
PHPQA_DOCKER_IMAGE=jakzal/phpqa:1.87.0-php${PHP_VERSION}-alpine
PHPQA_DOCKER_IMAGE=jakzal/phpqa:1.91.0-php${PHP_VERSION}-alpine
endif

ifndef PHPQA_DOCKER_COMMAND
Expand Down
1 change: 1 addition & 0 deletions resources/PHP/php-cs-fixer.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
'method_chaining_indentation' => false,
'multiline_whitespace_before_semicolons' => ['strategy' => 'new_line_for_chained_calls'],
'not_operator_with_successor_space' => true,
'nullable_type_declaration_for_default_null_value' => true,
'ordered_interfaces' => true,
'php_unit_internal_class' => true,
'php_unit_size_class' => true,
Expand Down
2 changes: 1 addition & 1 deletion resources/Visual/common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ $(error BASE_URL must be defined before loading Visual/common.mk)
endif

PROJECT_ROOT = ${DOCKER_CWD}
BACKSTOP_DOCKER_IMAGE ?= backstopjs/backstopjs:6.2.1
BACKSTOP_DOCKER_IMAGE ?= backstopjs/backstopjs:6.2.2
BACKSTOP_DOCKER_COMMAND ?= docker run --init --interactive ${TTY} --shm-size 256MB --cap-add=SYS_ADMIN --rm --env PROJECT_ROOT=${PROJECT_ROOT} --env BASE_URL=${BASE_URL} ${DOCKER_USER} --tmpfs /tmp --volume "${PROJECT_ROOT}:${PROJECT_ROOT}" --workdir "${PROJECT_ROOT}" ${BACKSTOP_DOCKER_IMAGE} --config backstop.config.js
visual/test:
${BACKSTOP_DOCKER_COMMAND} test
Expand Down
16 changes: 8 additions & 8 deletions tests/functional/MakefileTestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ abstract protected function getExpectedInitPaths(): array;

public function testMakefileExists(): void
{
static::assertFileExists(
self::assertFileExists(
$this->getRoot().\DIRECTORY_SEPARATOR.$this->getMakefilePath()
);
}
Expand All @@ -86,15 +86,15 @@ public function testMakefileHasHelp(): void
$expected = preg_replace('/\r\n|\r|\n/', "\n", $this->stripColoring($expected));
}

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

public function testHelpIsTheDefaultCommand(): void
{
$expected = $this->dryRun('help');
$actual = $this->dryRun();

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

public function testMakefileHasInit(): void
Expand All @@ -103,19 +103,19 @@ public function testMakefileHasInit(): void
$expected = array_merge(...array_values(array_map(static fn ($value) => [$value, 'if [ -f .gitattributes.dist ]; then mv .gitattributes.dist .gitattributes; fi'], $expected)));
$actual = $this->dryRun('init');

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

/**
* @dataProvider provideHelpCommandsExecutionPathFixtures
* @dataProvider provideMakefileCommandsWorkCases
*
* @param array<string, string> $env
*/
public function testMakefileCommandsWork(string $command, array $expected, array $env): void
{
$actual = $this->dryRun($command, env: $env);

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

/**
Expand Down Expand Up @@ -188,15 +188,15 @@ protected function generatePermissionsExecutionPath(array $dirs): array
/**
* @return iterable<array-key, array{string, list<string>, array<string, string>}>
*/
public function provideHelpCommandsExecutionPathFixtures(): iterable
public function provideMakefileCommandsWorkCases(): iterable
{
$commands = $this->getMakefileHelpCommands();

$envs = $this->getEnvs();
foreach ($envs as $env) {
$expected = $this->getExpectedHelpCommandsExecutionPath($env);
foreach ($commands as $command) {
static::assertArrayHasKey($command, $expected, sprintf('No expected execution path defined for command "%1$s"', $command));
self::assertArrayHasKey($command, $expected, sprintf('No expected execution path defined for command "%1$s"', $command));
}

foreach ($expected as $command => $path) {
Expand Down
4 changes: 2 additions & 2 deletions tests/functional/PHP/LibraryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public function testCanRunComposerInstallLowest(): void
$expected = array_merge($mkdir, $composer);
$actual = $this->dryRun('composer/install-lowest');

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

public function testCanRunComposerInstallHighest(): void
Expand All @@ -47,7 +47,7 @@ public function testCanRunComposerInstallHighest(): void
$expected = array_merge($mkdir, $composer);
$actual = $this->dryRun('composer/install-highest');

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

protected function getExpectedInitPaths(): array
Expand Down
4 changes: 2 additions & 2 deletions tests/functional/PHP/PharTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public function testCanRunComposerInstallLowest(): void
$expected = array_merge($mkdir, $composer);
$actual = $this->dryRun('composer/install-lowest');

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

public function testCanRunComposerInstallHighest(): void
Expand All @@ -51,7 +51,7 @@ public function testCanRunComposerInstallHighest(): void
$expected = array_merge($mkdir, $composer);
$actual = $this->dryRun('composer/install-highest');

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

protected function getExpectedInitPaths(): array
Expand Down
2 changes: 1 addition & 1 deletion tests/functional/PHP/PhpTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ private function paths(?array $env): array
{
// defaults which are also defined in the Makefile
$phpVersion = $env['PHP_VERSION'] ?? '8.2';
$phpqaDockerImage = $env['PHPQA_DOCKER_IMAGE'] ?? 'jakzal/phpqa:1.87.0-php%1$s-alpine';
$phpqaDockerImage = $env['PHPQA_DOCKER_IMAGE'] ?? 'jakzal/phpqa:1.91.0-php%1$s-alpine';

return [
'analyze' => [
Expand Down
2 changes: 1 addition & 1 deletion tests/functional/Pimcore/ApplicationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function testCanRunComposerInstall(): void

$filesystem->rename('composer.lock.old', 'composer.lock');

static::assertSame($expected, $actual);
self::assertSame($expected, $actual);
}

protected function setUp(): void
Expand Down
4 changes: 2 additions & 2 deletions tests/functional/YASSG/CompatTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public function testDevServerWorks(): void
private function generateDockerBackstopExecutionPath(string $command): string
{
return sprintf(
'docker run --init --interactive --shm-size 256MB --cap-add=SYS_ADMIN --rm --env PROJECT_ROOT=$ROOT --env BASE_URL=file://localhost$ROOT/public %2$s --tmpfs /tmp --volume "$ROOT:$ROOT" --workdir "$ROOT" backstopjs/backstopjs:6.2.1 --config backstop.config.js %1$s',
'docker run --init --interactive --shm-size 256MB --cap-add=SYS_ADMIN --rm --env PROJECT_ROOT=$ROOT --env BASE_URL=file://localhost$ROOT/public %2$s --tmpfs /tmp --volume "$ROOT:$ROOT" --workdir "$ROOT" backstopjs/backstopjs:6.2.2 --config backstop.config.js %1$s',
$command,
$this->generateDockerComposeExecutionUser()
);
Expand All @@ -120,7 +120,7 @@ private function generateDockerBackstopExecutionPath(string $command): string
private function generateDockerLighthouseExecutionPath(string $command): string
{
return sprintf(
'docker run --init --interactive --rm --env HOME=/tmp %2$s --volume "$ROOT:/public" --workdir "/public" cypress/browsers:node-18.16.0-chrome-112.0.5615.121-1-ff-112.0.1-edge-112.0.1722.48-1 %1$s',
'docker run --init --interactive --rm --env HOME=/tmp %2$s --volume "$ROOT:/public" --workdir "/public" cypress/browsers:node-20.5.0-chrome-114.0.5735.133-1-ff-114.0.2-edge-114.0.1823.51-1 %1$s',
$command,
$this->generateDockerComposeExecutionUser()
);
Expand Down

0 comments on commit e34c9b4

Please sign in to comment.