Commit Graph

244 Commits

Author SHA1 Message Date
Ingo Schommer
9e9ec33dd3 MINOR: Fixed bugs with test execution. (from r96829)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102404 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 03:24:29 +00:00
Ingo Schommer
9fc3256025 BUGFIX: Don't let Versioned archive tables clutter the global state when testing.
BUGFIX: Don't let mocked datetimes clutter the global state when testing. (from r96640) (from r96648) (from r96774)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102403 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 03:21:30 +00:00
Ingo Schommer
7c14bd233a MINOR: Give all test ADMIN privileges by default (from r92208) (from r96747)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102374 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 02:36:14 +00:00
Ingo Schommer
e19d18d3c9 BUGFIX: Fixed bug that was caused by r97583 (from r97589)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102358 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 02:14:33 +00:00
Ingo Schommer
e921b376bc API CHANGE: Don't generate TestOnly DataObjects in the database immediately; instead let test developers specify them in SapphireTest::$extraDataObjects.
API CHANGE: Added SapphireTest::resetDBSchema() (from r90054) (from r96734)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102356 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 02:03:16 +00:00
Ingo Schommer
19c03a0bd9 MINOR: Flush get_one cache after rebuilding database schema. (from r89966) (from r96730)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102352 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 01:54:33 +00:00
Ingo Schommer
093da7592a API CHANGE: Renamed SapphireTest::set_up_once/tear_down_once to setUpOnce/tearDownOnce, and made them instance methods.
API CHANGE: Added SapphireTest::$illegalExtensions and SapphireTest::$requiredExtensions for making tests depending on particular extension sets (from r89958) (from r96727)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@102350 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-04-12 01:52:39 +00:00
Ingo Schommer
2fc2d72501 BUGFIX Fixed DataObject->fieldLabels() to respect flag
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@98748 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-02-11 02:18:54 +00:00
Andrew Short
82df67ac81 MINOR: Moved the YamlFixture class into the dev directory.
From: Andrew Short <andrewjshort@gmail.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@97399 467b73ca-7a2a-4603-9d3b-597d59a354a9
2010-01-21 22:59:17 +00:00
Sean Harvey
848a254da7 BUGFIX If running a BuildTask via AJAX, e.g. Filesystem::sync() is run from AssetAdmin, don't show the message "Running [task] ..." (from r95169)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@95635 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-16 05:49:23 +00:00
Sean Harvey
e64443b50d MINOR: added cookies to Director::test() (from r94684)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@95620 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-16 05:42:43 +00:00
Sean Harvey
b79c2149d9 ENHANCEMENT Allow passing in an Exception object to SS_Log::log() in addition to an array describing the error context (line number, file, trace etc) (from r94423)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@95609 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-16 05:40:52 +00:00
Sean Harvey
3665c59fff MINOR Documentation updates to SS_Log (from r94418)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@95607 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-16 05:40:40 +00:00
Sean Harvey
63ce0bd4ec ENHANCEMENT Added FunctionalTest::findAttribute() as a helper for getting an attribute from a SimpleXMLElement object by it's name (from r94381)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@95605 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-16 05:40:27 +00:00
Sean Harvey
424ad27d08 MINOR: Tweak to test name display on the test runner (from r94336)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@95597 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-16 05:38:42 +00:00
Sam Minnee
35c6b15edc MINOR: Don't use test manifest for dev/startsession and dev/endsession (from r93528)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@94431 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-06 02:48:32 +00:00
Ingo Schommer
ef28a27b25 ENHANCEMENT Added BulkLoader->deleteExistingRecords(), removed unnecessary parameters from BulkLoader->load()
ENHANCEMENT Decreased memory usage in BulkLoader->load() when deleting all records before importing
MINOR Re-enabled CsvBulkloaderTest cases, were disabled by accident

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@94250 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-12-02 09:40:28 +00:00
Ingo Schommer
261f8f897a BUGFIX Added Hierarchy::reset() to manually clear marked/expanded states triggered through Hierarchy->markExpanded() etc. This caused side effects when running e.g. CMSMainSearchFormTest and HierarchyTest alongside each other.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@93987 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-30 02:24:46 +00:00
Ingo Schommer
ba344f2531 ENHANCEMENT Added SapphireTest->usesDatabase flag to explicitly request building of a test database for a test suite. This is necessitated by r93717, which removed the automatic building of these databases on every run.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@93975 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-30 01:48:26 +00:00
Sean Harvey
cef45bb95a BUGFIX Fixed newlines for Windows when logging errors in LogErrorFileFormatter (from r93161)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@93749 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-27 01:26:03 +00:00
Sam Minnee
66e4b42942 ENHANCEMENT: Don't set up the test db if database tests aren't being run.
From: Sam Minnee <sam@silverstripe.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@93717 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-27 00:24:56 +00:00
Ingo Schommer
f3c0cbc1ab BUGFIX Setting HTTP status in current controller for Debug::friendlyError() to avoid it being overwritten in HTTPResponse->output() later in the execution chain
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@92535 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-21 02:31:30 +00:00
Ingo Schommer
143dae483f MINOR: Make pass use a password field, dont require call by reference (merged from r72930)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@92259 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-19 20:23:19 +00:00
Sam Minnee
4252067f0c MINOR Changed silverstripe.com references to silverstripe.org
MINOR Fixed broken wiki links (#4672) (from r90886)

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@90957 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-11-06 03:35:07 +00:00
Andrew Short
79773042be API CHANGE: Renamed conflicting classes to have an "SS_" namespace, and renamed existing "SS" namespace to "SS_". The affected classes are: HTTPRequest, HTTPResponse, Query, Database, SSBacktrace, SSCli, SSDatetime, SSDatetimeTest, SSLog, SSLogTest, SSLogEmailWriter, SSLogErrorEmailFormatter, SSLogErrorFileFormatter, SSLogFileWriter and SSZendLog.
MINOR: Replaced usage of renamed classes with the new namespaced name.

From: Andrew Short <andrewjshort@gmail.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@90075 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-26 03:06:31 +00:00
Sam Minnee
599adc97b1 API CHANGE: Added dev/tests/build, which runs everything, meaning that dev/tests/all doesn't need to run PhpSyntaxTes
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@90059 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-23 03:06:59 +00:00
Ingo Schommer
e1a47de20e BUGFIX Fixing regression in TranslatableTest due to outdated singleton caching.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89911 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-22 00:30:21 +00:00
Ingo Schommer
11d5ce0274 BUGFIX Moved SINGLETON resetting for test runs from SiteTreeTest/ObjectTest into SapphireTest - there should be no caching between all test invocations to avoid side effects
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89893 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-21 23:09:14 +00:00
Sean Harvey
84c9f8efd0 BUGFIX Removed double up of classes in TestRunner::coverage() (from r88463)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89798 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-21 04:06:29 +00:00
Sean Harvey
1e09bc4907 MINOR Check that the error file exists in Debug (from r82791)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89723 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-21 02:32:55 +00:00
Ingo Schommer
5018dc0ada MINOR Fixed assignment by reference in TestSession->lastPage() (deprecated in PHP 5.3)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89244 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-16 01:21:53 +00:00
Sam Minnee
bc6b3804b6 API CHANGE: Added SapphireTest::logInWithPermission() (from r89012)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@89209 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-15 22:40:17 +00:00
Sean Harvey
57ab419736 MINOR Updated class documentation for SSLog to fix inaccurate class name, when it should actually be "SSLogEmailWriter"
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@88950 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-14 06:29:05 +00:00
Sam Minnee
cad7d5e859 ENHANCEMENT: Make base tag in 404 page dynamic (from r72282)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@88633 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-12 03:23:10 +00:00
Sam Minnee
c347278dda API CHANGE: Added Debug::$friendly_error_header and Debug::$friendly_error_detail for customising the friendly error message. (from r69855)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@88632 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-12 03:20:24 +00:00
ajshort
97ac0008b3 ENHANCEMENT: Cached the value for RootURLController::get_homepage_link() between calls.
From: ajshort <andrewjshort@gmail.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@88504 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-11 00:07:22 +00:00
Andrew Short
d2a1f25d16 BUGFIX #3862: Explicitly defined browsing and viewing actions on CodeViewer.
From: Andrew Short <andrewjshort@gmail.com>

git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@88473 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-10-11 00:06:57 +00:00
Sean Harvey
b77d088d47 Merged in parent::__construct() additions from branches/2.3 - r83580 and r83587
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86676 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-18 03:02:19 +00:00
Ingo Schommer
e7add7a943 MINOR Dont trim strings in Debug::message(), they are useful for indentation
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86222 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-14 05:41:28 +00:00
Ingo Schommer
a4cd246a72 BUGFIX Return FALSE in SapphireTest->assertDOSEquals() if no valid DataObjectSet is passed in
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86217 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-14 05:16:15 +00:00
Sean Harvey
3386e8223a MINOR Removed unnecessary $bt variable in Debug::errorHandler()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86176 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-13 23:23:02 +00:00
Ingo Schommer
5708f79312 BUGFIX Consistently returning from a Security::permissionFailure() to avoid ambiguous situations when controllers are in ajax mode
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86008 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-10 02:00:42 +00:00
Ingo Schommer
0cf75cfc65 MINOR Unified permission control for i18nTextCollectorTask, TaskRunner, TestRunner, ModelViewer, DevelopmentAdmin, TestViewer, MigrateTranslatableTask
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86005 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-10 01:49:56 +00:00
Ingo Schommer
7a27726d00 MINOR Removed alpha stage ModuleManager into new "modulemanager" module. Was never released, and won't be suitable for 2.4.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@86000 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-10 01:34:20 +00:00
Julian Seidenberg
2cf002e333 ENHANCEMENT: added option to truncate (clear) database table before importing a new CSV file with CSVBulkerLoader and ModelAdmin.
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@85709 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-09-04 00:31:08 +00:00
Ingo Schommer
fec369531c MINOR Added SiteTree::reset() to unset any in-memory caches (see DataObject::reset()). Using reset() in SapphireTest to avoid caches persisting across multiple tests
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@85337 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-27 06:55:32 +00:00
Ingo Schommer
1a7418c18b BUGFIX Disabled PHPUnit backup of global variables, which caused i18n::_t() calls in subsequent test cases to fail because of a cached empty global
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@85330 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-27 04:45:58 +00:00
Sean Harvey
87bb1acadb BUGFIX #3713 Escape HTTP request URL properly in DebugView::writeError() using htmlentities()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@85136 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-25 03:11:22 +00:00
Sam Minnee
19769e3841 API CHANGE: Added DataObjectSet assertions to SapphireTest
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@85073 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-24 06:14:54 +00:00
Sam Minnee
d34963df8a API CHANGE: Added comparison argument to SSLog::add_writer()
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@85028 467b73ca-7a2a-4603-9d3b-597d59a354a9
2009-08-24 03:21:12 +00:00