45 Commits

Author SHA1 Message Date
Brad Dutton
96e7f17a67 changes to get tests passing with PHP 8 2021-04-23 14:33:53 -07:00
bwdutton
9686d6876c only one item was deprecated, re-enable full tests 2020-02-01 16:29:40 -08:00
bwdutton
6a686d3b03 switch travis to php 7.0
don't fail on deprecated function warnings
remove debug
2020-02-01 15:14:07 -08:00
shadlaws
b036b8acc0 Follow-on fix: if tests throw an exception, don't throw another by calling an undefined variable. 2013-03-10 11:27:10 +01:00
Bharat Mediratta
59ea4a6a31 Follow-on fix: count errors as well as test failures. 2013-03-06 17:04:54 -05:00
Bharat Mediratta
f0064643c2 Set exit status to the number of failed tests. This should fix issues with Travis. 2013-03-06 16:45:38 -05:00
Bharat Mediratta
feed100337 Revert "Return "1" to CLI if not all unit tests pass.". We're not successfully
passing back $all_passed because the function doesn't take it by reference.  Which
is my fault because I gave Jozefs bad advice.  But I don't think it's necessary anyway
so I'm going to try a different approach.

This reverts commit 4fe07c6b0a.

Conflicts:
	modules/gallery_unit_test/controllers/gallery_unit_test.php
2013-03-06 16:38:38 -05:00
Bharat Mediratta
d136a035e3 Explicitly print out the exit status to see if I can narrow down failures on Travis. 2013-03-06 16:13:49 -05:00
Jozef Selesi
4fe07c6b0a Return "1" to CLI if not all unit tests pass. 2013-03-04 23:29:47 +01:00
Bharat Mediratta
f72c5a87c8 Follow-on to 9396342250 for #1985 which
was breaking all unit tests.  Use module::install("gallery") instead
of calling gallery_installer::install directly.
2013-01-31 23:45:36 -05:00
Bharat Mediratta
d45a737779 Update copyright to 2013. Fixes #1953. 2013-01-21 01:22:01 -05:00
Bharat Mediratta
bf2bb3e1ea Update copyright to 2012. #1822 2012-02-27 09:48:23 -08:00
Bharat Mediratta
423daa52d5 Update copyright to 2011. 2011-01-21 23:01:06 -08:00
Bharat Mediratta
587284ab38 Move the test time limit code into Unit_Test since some parts of the
code (like ORM_MPTT) mess with the time limit which interferes with
the overall time limit set in Gallery_Unit_Test_Controller.
2010-12-15 11:17:22 -08:00
Bharat Mediratta
1cc3d130bc Set the unit test timeout to 5 minutes 2010-10-25 21:04:40 -07:00
Bharat Mediratta
5151f0b865 Improve a comment. 2010-06-07 22:18:09 -07:00
Bharat Mediratta
c3c2b45280 Update the copyright to 2010. It's only 3 months into the year :-) 2010-03-03 10:15:34 -08:00
Bharat Mediratta
c050acf30a Fix lots of warnings that pop up when we're in E_STRICT mode. They're
mostly issues around uninitialized variables, calling non-static
functions in a static context, calling Session functions directly
instead of on its singleton, passing non-variables by reference, and
subclasses not using the same interface as the parent class.
2010-01-31 16:07:41 -08:00
Bharat Mediratta
f70130b820 Special case output for ORM_Validation_Exceptions 2010-01-17 13:30:06 -08:00
Bharat Mediratta
287f79dd72 Updated for K24 2009-12-21 11:30:06 -08:00
Bharat Mediratta
4a417708f0 Kohana::show_404() -> throw new Kohana_404_Exception() 2009-11-25 13:51:33 -08:00
Tim Almdal
2a21f3bc80 Only install and activate modules that have tests to run. 2009-10-28 11:37:05 -07:00
Tim Almdal
703f22abcb Only look for tests that are in the active modules. Update the controller golden file to reflect the current location of files. 2009-10-23 09:41:33 -07:00
Tim Almdal
94cd07805d Change the gallery_unit test to only intall into the test environment, modules that are active in the non-test environment. 2009-10-23 07:49:14 -07:00
Bharat Mediratta
79754c2ef4 Run 'graphics::choose_default_toolkit();' to pick a toolkit, which we
normally do as part of a regular install.
2009-09-02 11:53:10 -07:00
Bharat Mediratta
0157ed4cfe Update test code to match the change made in 47810c9aec
where we adjust the site_domain in config.php
2009-06-10 00:53:16 -07:00
Bharat Mediratta
20a2d9f9a8 Reset the cascading file path properly before reinstalling. 2009-05-28 20:59:23 -07:00
Bharat Mediratta
3da5ee2f4c Print out exception traces for most errors 2009-05-28 18:21:39 -07:00
Bharat Mediratta
5e7cc75a29 Convert a few more references of APPPATH to MODPATH/gallery 2009-05-27 16:29:33 -07:00
Bharat Mediratta
88a3d43ba9 Update all references to the core application to now point to the
gallery module.  This type of mass update is prone to some small bugs.
2009-05-27 16:17:29 -07:00
Bharat Mediratta
7aed923908 Restructure the module lifecycle.
Install: <module>_installer::install() is called, any necessary tables
are created.

Activate: <module>_installer::activate() is called.  Module
controllers are routable, helpers are accessible, etc.  The module is
in use.

Deactivate: <module>_installer::deactivate() is called.  Module code
is not accessible or routable.  Module is *not* in use, but its tables
are still around.

Uninstall: <module>_installer::uninstall() is called.  Module is
completely removed from the database.

Admin > Modules will install and activate modules, but will only
deactivate (will NOT uninstall modules).
2009-05-26 05:28:59 +00:00
Bharat Mediratta
5495037a3d Gee it's May already. Update copyright to 2009. 2009-05-13 20:04:58 +00:00
Bharat Mediratta
61d8a143ea Rejigger the way we do reinstalls while Kohana is running.
core_installer::install() now takes an $initial_install param that
allows us to enforce that we're doing a clean install.  Use this in
both the scaffolding and the unit test code.

Greatly simplify the scaffolding uninstall/reinstall code.
2009-03-19 02:35:51 +00:00
Bharat Mediratta
8dd24edf73 Fix correctness issue if there are no tables (list_tables will return null)
Clean out the module caches directly now that the module loading robustness code is gone.
2009-03-17 18:16:54 +00:00
Andy Staudacher
41600a982f Fix bootstrap / installation issue for unit test framework:
Install user module before installing other modules. E.g. local_import's installation routine depends on the user module to be installed.
2009-02-24 05:27:07 +00:00
Bharat Mediratta
f2cfd9798e Use xxx_test as the default database name. This means that we no
longer have to manually tweak database.php, yay!
2009-01-20 09:40:14 +00:00
Andy Staudacher
fd081159f1 Windows fixes: Use mkdir($path, 0777, true) instead of the unportable system("mkdir -p $path") 2009-01-08 06:57:04 +00:00
Bharat Mediratta
8bd7afeb5b TEST_MODE always exists now, so check its value, don't rely on its existence to know that we're in test mode. 2008-12-16 05:13:04 +00:00
Bharat Mediratta
ee688d1f37 Reload modules *after* we blow away the database to flush out caches 2008-12-13 08:37:41 +00:00
Bharat Mediratta
e12451cf10 Refaactor module::install() and module::uninstall() out of the
scaffolding and unit test code so that we can use it consistently.
This fixes an issue where adding a module was not refreshing the
statically cached module list causing the test framework to break.
2008-12-12 08:41:48 +00:00
Bharat Mediratta
b54b34ed78 Pass list of test dirs into Unit_Test::_constructor() as an argument
instead of modifying the config.
2008-12-12 05:39:06 +00:00
Bharat Mediratta
80a7db61c9 Fix up the test framework to work now that we're only loading installed modules
via the autoloader.
2008-12-04 08:17:57 +00:00
Bharat Mediratta
844e5573f0 Make sure that the dev is not using the same db for tests as they are for production (this one's for you, valiant!) 2008-12-03 03:49:45 +00:00
Bharat Mediratta
705698a425 Drop the database and rm -rf test/var instead of calling uninstall on
all modules.  This guarantees a clean start w/out worrying about
weirdness in the uninstaller code.
2008-12-03 03:44:48 +00:00
Bharat Mediratta
6f959deed9 Rename generic test.php to gallery_unit_test.php to make navigation to this file a little easier 2008-12-03 03:23:30 +00:00