-
Notifications
You must be signed in to change notification settings - Fork 1
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
Add test DB for testing on docker #22
Add test DB for testing on docker #22
Conversation
The original code tested wheter the DB connection could be setup and not if the code actually did what is what supposed to do. Refactor it so it tests code written in Act::Database. This change also eliminates the need for Act::Config as the functions don't need any configuration, just a database handle which Test::MockObject now provides to us.
This reverts commit b8b3d29.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Regarding new configuration variables: Due to the way Act works, every variable which is used in the code must also be present in the configuration, otherwise you get a warning for every request. Therefore a list of variables must be available at least in the documentation, if not with a comment in act.ini.dist.
After some annoying shuffling of directories I got it down to two failing test files:
Related: 89cffdf needs to be reverted with the undoing of the changes in I18N.pm. With a working I18N environment, the "a" element is provided by the .po files and must not be part of the templates. |
Can you tell me what you have in your act.ini, and what your conference.ini looks like. Because my tests are failing hard on t/02config.t and t/11talk.t. |
If you just run t/02config.t in verbose mode, it will tell you which variables are missing. My own setup is pretty customized with four conferences in different languages, among them Russian (for Unicode tests), so 02config.t runs 296 individual tests. The conference configs are pulled from the Act-Conferences repository without changes.
With the same config act.ini.dist, t/11talks.t fails in my setup because it refers to a test database host which I don't have. It would be helpful to know which of the tests are failing: maybe the database setup or cleanup after the tests fails. I have no indication why t/11talks.t should behave different from any other tests using the database, It is using a non-existing conference, so the conference setup should not matter. |
I already found out. My branch was on v10 for DB upgrades and yours is v12. So I added them in |
Ok, that one is also fixed. |
Template::Toolkit takes care of the creation of this directory
This reverts commit 1ce96ac.
Exciting times! 👍
|
This is a couple of commits that fixes a lot of the testsuite. We still aren't were we want to be, but there is progress.