Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Run the test, get three errors. #17684

Closed
tttfujita opened this issue May 12, 2024 · 2 comments · Fixed by #17691
Closed

Run the test, get three errors. #17684

tttfujita opened this issue May 12, 2024 · 2 comments · Fixed by #17691
Labels
Milestone

Comments

@tttfujita
Copy link

Description

OS: Ventura 13.6.6

When I run the test I get three errors.
composer test

Is this expected behaviour?
As there are no problems, should I not be concerned about those errors?

% composer test
> phpunit
PHPUnit 10.5.3 by Sebastian Bergmann and contributors.

Runtime:       PHP 8.3.7
Configuration: /cakephp/phpunit.xml.dist

WPHP Warning:  /private/var/folders/vc/n70fwzx54f52rd49yn9lghn40000gn/T/cache/tmp_4bKIeq/ is not writable in /cakephp/src/Cache/Engine/FileEngine.php on line 424

Warning: /private/var/folders/vc/n70fwzx54f52rd49yn9lghn40000gn/T/cache/tmp_4bKIeq/ is not writable in /cakephp/src/Cache/Engine/FileEngine.php on line 424

There were 3 errors:

1) Cake\Test\TestCase\Database\Schema\MysqlSchemaTest::testDescribeTableFunctionalIndex
Cake\Database\Exception\DatabaseException: Columns used in index `child_ids_idx` in table `functional_index` must be added to the Table schema first. The column `` was not found.

/cakephp/src/Database/Schema/TableSchema.php:492
/cakephp/src/Database/Schema/SqliteSchemaDialect.php:389
/cakephp/src/Database/Schema/Collection.php:161
/cakephp/src/Database/Schema/Collection.php:121
/cakephp/tests/TestCase/Database/Schema/MysqlSchemaTest.php:557
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:1116
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:655
/cakephp/vendor/phpunit/phpunit/src/Framework/TestRunner.php:103
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:489
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/TextUI/TestRunner.php:63
/cakephp/vendor/phpunit/phpunit/src/TextUI/Application.php:189

2) Cake\Test\TestCase\Database\SchemaCacheTest::testBuildEnablesMetadataCache
Cake\Database\Exception\DatabaseException: Columns used in index `child_ids_idx` in table `functional_index` must be added to the Table schema first. The column `` was not found.

/cakephp/src/Database/Schema/TableSchema.php:492
/cakephp/src/Database/Schema/SqliteSchemaDialect.php:389
/cakephp/src/Database/Schema/Collection.php:161
/cakephp/src/Database/Schema/Collection.php:121
/cakephp/src/Database/Schema/CachedCollection.php:92
/cakephp/src/Database/SchemaCache.php:65
/cakephp/tests/TestCase/Database/SchemaCacheTest.php:96
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:1116
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:655
/cakephp/vendor/phpunit/phpunit/src/Framework/TestRunner.php:103
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:489
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/TextUI/TestRunner.php:63
/cakephp/vendor/phpunit/phpunit/src/TextUI/Application.php:189

3) Cake\Test\TestCase\Database\SchemaCacheTest::testBuildNoArgs
Cake\Database\Exception\DatabaseException: Columns used in index `child_ids_idx` in table `functional_index` must be added to the Table schema first. The column `` was not found.

/cakephp/src/Database/Schema/TableSchema.php:492
/cakephp/src/Database/Schema/SqliteSchemaDialect.php:389
/cakephp/src/Database/Schema/Collection.php:161
/cakephp/src/Database/Schema/Collection.php:121
/cakephp/src/Database/Schema/CachedCollection.php:92
/cakephp/src/Database/SchemaCache.php:65
/cakephp/tests/TestCase/Database/SchemaCacheTest.php:107
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:1116
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:655
/cakephp/vendor/phpunit/phpunit/src/Framework/TestRunner.php:103
/cakephp/vendor/phpunit/phpunit/src/Framework/TestCase.php:489
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/Framework/TestSuite.php:340
/cakephp/vendor/phpunit/phpunit/src/TextUI/TestRunner.php:63
/cakephp/vendor/phpunit/phpunit/src/TextUI/Application.php:189

ERRORS!
Tests: 7776, Assertions: 23125, Errors: 3, Warnings: 79, Deprecations: 1, Skipped: 324, Incomplete: 3.
Script phpunit handling the test event returned with error code 2

CakePHP Version

5.x

PHP Version

8.3.7

@markstory
Copy link
Member

Is this expected behaviour?

No, tests should pass. What version of MySQL are you running tests against?

@dereuromark
Copy link
Member

For me they also pass (latest 5.x). Both default sqlite and mysql.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants