GithubHelp home page GithubHelp logo

Comments (4)

davidyell avatar davidyell commented on July 17, 2024

This is because it reads the schema for the table class, which stipulates that column type so the behaviour can process the file.

You'll need to manually change your fixture. There was some discussion about the root issue , but I can't find it now, the upshot was that the data type class should implement the base type of string.

Perhaps that needs to happen in the plugin? Either through class FileType extends StringType

from cakephp-upload.

tbelknapsgs avatar tbelknapsgs commented on July 17, 2024

Thank you, David. This makes sense, just wasn't sure if this was the expected behavior, or not. Closing ticket.

from cakephp-upload.

AdrianHL avatar AdrianHL commented on July 17, 2024

I found this issue happening when running filtered tests.

The solution we found is to load the plugin in the test class so that the application was bootstrapped as expected as described in https://book.cakephp.org/4/en/development/testing.html#integration-testing-psr-7-middleware

PS. The app is on CakePHP 4.2, PHP 8.1 and PHPUnit 9.5.

from cakephp-upload.

RichardPiel avatar RichardPiel commented on July 17, 2024

I got same error but i don't use fixtures but migrations to initialize test database.

Do you have solution to avoid this behavior ?

Thanks

Edit: i loaded plugin in my test case, but i always got the same error.
Edit2: Fixed, i had to load plugins before parent::setUp();

from cakephp-upload.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.