From 3682a4e8a38c502dc81416971a0be302f121bdad Mon Sep 17 00:00:00 2001 From: Sam Wilson Date: Thu, 29 Feb 2024 08:31:49 +0800 Subject: [PATCH] Change the Commons test file (#729) The Test.svg file gets changed by people sometimes, causing the svgtranslate CI tests to fail, so to avoid issues this switches to a file that's specifically labelled as being used for this purpose. Also fix an indent in ci.yml. --- .github/workflows/ci.yml | 2 +- tests/Controller/TranslateControllerTest.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 69e610c2..f5142f92 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,7 +45,7 @@ jobs: - name: Build run: | - npm run build + npm run build - name: Test run: | diff --git a/tests/Controller/TranslateControllerTest.php b/tests/Controller/TranslateControllerTest.php index 295473de..80602724 100644 --- a/tests/Controller/TranslateControllerTest.php +++ b/tests/Controller/TranslateControllerTest.php @@ -15,10 +15,10 @@ class TranslateControllerTest extends WebTestCase public function testExists(): void { $client = static::createClient(); - $crawler = $client->request('GET', '/File:Test.svg'); + $crawler = $client->request('GET', '/File:SVG_Translate_test_-_valid.svg'); $response = $client->getResponse(); static::assertEquals(200, $response->getStatusCode()); - static::assertStringContainsString('Test.svg', $crawler->filter('h1')->text()); + static::assertStringContainsString('SVG Translate test - valid.svg', $crawler->filter('h1')->text()); } public function testNonSvgHandling(): void