Commit Graph

39 Commits

Author SHA1 Message Date
Petr Skoda c691274bf9 MDL-32323 use new loadDataSet in mod_data and fix typos in last commit 2012-04-10 21:07:56 +02:00
Petr Skoda e396e8ed5f MDL-32323 implement data set loader support in advanced_testcase 2012-04-10 20:58:27 +02:00
Petr Skoda d2999716aa MDL-32323 all our base test case classes should be abstract 2012-04-10 19:03:24 +02:00
Petr Skoda 39e2e9c41f MDL-32323 prevent modification of our heavily modified runBare() methods
This should help with compatibility of future PHPUnit and it also allows us to improve test reset without breaking existing moodle test cases.
2012-04-10 15:27:14 +02:00
Petr Skoda 920f4efe51 MDL-32323 improve inline docs 2012-04-10 15:27:14 +02:00
Petr Skoda 95dcf96559 MDL-32323 allow mocking of global $DB 2012-04-10 15:27:13 +02:00
Petr Skoda ce9f3beb53 MDL-32323 automate transaction handling in test reset 2012-04-10 15:27:13 +02:00
Petr Skoda 713d20918f MDL-32323 reset state after failed test 2012-04-10 15:27:12 +02:00
Petr Skoda c06563c845 MDL-32323 do not pollution config-dist.php with settings that only DML driver devs use 2012-04-10 15:27:10 +02:00
Petr Skoda 7620602cc2 MDL-32323 improve transaction handling in PHPUnit test cases 2012-04-10 15:27:10 +02:00
Petr Skoda de3d1590ee MDL-32323 fix PHPUnit diag regression 2012-04-10 15:27:09 +02:00
Petr Skoda b6b8a19316 MDL-32323 improve PHPUnit related diagnotic messages 2012-04-10 15:27:08 +02:00
Petr Skoda e10736b3cc MDL-32323 improve mysql test reset performance 2012-04-10 15:27:08 +02:00
Petr Skoda e370154157 MDL-32323 make test locking win compatible 2012-04-10 15:27:08 +02:00
Petr Skoda 6c583c75f9 MDL-32323 do lot try to acquire lock before dataroot init 2012-04-10 15:27:07 +02:00
Petr Skoda 812013b1c1 MDL-32323 reset event handlers in phpunit test reset 2012-04-10 15:27:06 +02:00
Petr Skoda a0c5affee6 MDL-32323 test detection of changes and improve coding style 2012-04-10 15:27:05 +02:00
Petr Skoda ab483c0a07 MDL-32323 use auto_increment instead of primary_key for sequence detection and improve coding style 2012-04-10 15:27:05 +02:00
Petr Skoda 219d1a4e72 MDL-32323 improve self-diagnostic messages 2012-04-10 15:27:05 +02:00
Petr Skoda 8b5413ccf2 MDL-32323 rework db reset once more, now with tests 2012-04-10 15:27:05 +02:00
Petr Skoda 50be93d1d7 MDL-32323 add fast transaction based database reset for PostgreSQL 2012-04-10 15:27:04 +02:00
Petr Skoda 714f3998a8 MDL-32323 rework buggy database reset optimisation and fix blog tests 2012-04-10 15:27:04 +02:00
Petr Skoda 0b9251e330 MDL-32323 cache structure of all tables and reset sequences only in table where id is primary key 2012-04-10 15:27:04 +02:00
Petr Skoda fe35ccafe3 MDL-32323 fix recently borked detection of DB changes and improve coding style 2012-04-10 15:27:03 +02:00
Petr Skoda 4be2ad3660 MDL-32323 prevent concurrent execution of unit tests 2012-04-10 15:27:03 +02:00
Petr Skoda 6e2cff2d81 MDL-32323 minor phpunit related improvements and cleanup 2012-04-10 15:27:01 +02:00
Petr Skoda 7b0ff21385 MDL-32323 experimental web UI for execution of PHPUnit tests
It is not localised intentionally because only developers should use it…
2012-04-10 15:27:01 +02:00
Petr Skoda 4b17369567 MDL-32323 all-in-one PHPUnit init script 2012-04-10 15:27:01 +02:00
Petr Skoda 7fe8aac1a7 MDL-32149 add quiz unit tests 2012-04-03 22:31:02 +02:00
Petr Skoda e72ea4a5e4 MDL-32149 add basic file picker test and new way to set current user via int
Please note that testing of individual plugins should not be done in repositorylib_test.php.
2012-04-03 22:31:01 +02:00
Petr Skoda b0e980d77f MDL-32149 prevent accidental overriding of testcase constructors, use setUpBeforeClass() instead 2012-04-03 22:31:01 +02:00
Petr Skoda 03c2d04d0a MDL-32149 make complete PHPUnit test time 2s faster 2012-04-03 22:31:00 +02:00
Petr Skoda 1cbf2a20ca MDL-32149 setUp() and tearDown() are supposed to be 'protected', add missing blog testcase 2012-04-03 22:30:56 +02:00
Petr Skoda 728eadac78 MDL-32149 significantly faster database reset, "util.php --drop" can now be interrupted at any time 2012-04-03 22:30:54 +02:00
Petr Skoda dbf5a44798 MDL-32149 add backup tests and dropping of extra tables 2012-04-03 22:30:54 +02:00
Petr Skoda 458b33866d MDL-32149 reset all globals in PHPUnit tests, fix setting of $USER 2012-04-03 22:30:54 +02:00
Petr Skoda a3d5830a0a MDL-32149 PHPUnit test support - part 2
Includes:
* constants refactoring
* reworked db table init
* support for $CFG->debug = -1
* functional DB tests
* fixed $DB->get_indexes() to not throw exceptions when table does not exist
* fix handling of user passwords in test db
* add debug info to exception messages
* removed unnecessary PHP debug errors from mathslib
* fixed @error suppression in get_string
* fixed PHPUnit error handler setup
* added timezone info to default install
2012-04-03 22:30:53 +02:00
Sam Hemelryk 7aea08e1b0 MDL-31857 phpunit: PHPDoc and typo fixes during integration 2012-03-22 10:45:17 +13:00
Petr Skoda 5bd4040866 MDL-31857basic phpunit support
Thanks Eloy Lafuente, Tim Hunt and Sam Hemelryk for valuable feedback and ideas.
2012-03-21 10:31:37 +01:00