Skip to content

Conversation

@backportbot
Copy link

@backportbot backportbot bot commented Jun 18, 2024

Backport of PR #45228

@provokateurin provokateurin enabled auto-merge June 18, 2024 15:37
@skjnldsv skjnldsv mentioned this pull request Jun 20, 2024
4 tasks
@blizzz blizzz mentioned this pull request Jun 21, 2024
@kesselb
Copy link
Contributor

kesselb commented Jul 10, 2024

1) Test\Route\RouterTest::testGenerateConsecutively
Unexpected info log: Symfony\Component\Routing\Exception\RouteNotFoundException: Unable to generate a URL for the named route "files.view.index" as such route does not exist. in /home/runner/work/server/server/3rdparty/symfony/routing/Generator/UrlGenerator.php:144
Stack trace:
#0 /home/runner/work/server/server/lib/private/Route/Router.php(410): Symfony\Component\Routing\Generator\UrlGenerator->generate('files.view.inde...', Array, 1)
#1 /home/runner/work/server/server/tests/lib/Route/RouterTest.php(68): OC\Route\Router->generate('files.view.inde...')
#2 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/Framework/TestCase.php(1608): Test\Route\RouterTest->testGenerateConsecutively()
#3 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/Framework/TestCase.php(1214): PHPUnit\Framework\TestCase->runTest()
#4 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/Framework/TestResult.php(728): PHPUnit\Framework\TestCase->runBare()
#5 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/Framework/TestCase.php(964): PHPUnit\Framework\TestResult->run(Object(Test\Route\RouterTest))
#6 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/Framework/TestSuite.php(684): PHPUnit\Framework\TestCase->run(Object(PHPUnit\Framework\TestResult))
#7 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/Framework/TestSuite.php(684): PHPUnit\Framework\TestSuite->run(Object(PHPUnit\Framework\TestResult))
#8 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/Framework/TestSuite.php(684): PHPUnit\Framework\TestSuite->run(Object(PHPUnit\Framework\TestResult))
#9 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/TextUI/TestRunner.php(653): PHPUnit\Framework\TestSuite->run(Object(PHPUnit\Framework\TestResult))
#10 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/TextUI/Command.php(144): PHPUnit\TextUI\TestRunner->run(Object(PHPUnit\Framework\TestSuite), Array, Array, true)
#11 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/src/TextUI/Command.php(97): PHPUnit\TextUI\Command->run(Array, true)
#12 /home/runner/work/server/server/vendor-bin/phpunit/vendor/phpunit/phpunit/phpunit(98): PHPUnit\TextUI\Command::main()
#13 /home/runner/work/server/server/lib/composer/bin/phpunit(122): include('/home/runner/wo...')
#14 {main}

/home/runner/work/server/server/tests/lib/Route/RouterTest.php:50
/home/runner/work/server/server/lib/private/Route/Router.php:412
/home/runner/work/server/server/tests/lib/Route/RouterTest.php:68

@kesselb
Copy link
Contributor

kesselb commented Jul 10, 2024

Pushed 76efdb0 to fix the failing test.

The router uses include_once to load route definitions from the apps.

First include_once for apps/files/appinfo/routes.php returns the expected array.

Second include_once returns true, because the file was already included.

To workaround the tests must run in a separate process.

I have no idea why the test is not failing on master.

@kesselb
Copy link
Contributor

kesselb commented Jul 10, 2024

To workaround the tests must run in a separate process.

That does not seem to work

I have no idea why the test is not failing on master.

The test is not failing on master because the app manager instance is mocked, the app path is null and the routing file not even included: #46416

@AndyScherzinger AndyScherzinger force-pushed the backport/45228/stable29 branch from de1f1a8 to a554ba5 Compare July 10, 2024 21:35
@provokateurin provokateurin merged commit 6167a4a into stable29 Jul 10, 2024
@provokateurin provokateurin deleted the backport/45228/stable29 branch July 10, 2024 23:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants