diff --git a/src/CRM/CivixBundle/Resources/views/Code/test-api.php.php b/src/CRM/CivixBundle/Resources/views/Code/test-api.php.php index 55bec374..a5f280cc 100644 --- a/src/CRM/CivixBundle/Resources/views/Code/test-api.php.php +++ b/src/CRM/CivixBundle/Resources/views/Code/test-api.php.php @@ -18,9 +18,13 @@ class extends \PHPUnit_Framework_TestCase implement * See: https://github.com/civicrm/org.civicrm.testapalooza/blob/master/civi-test.md */ public function setUpHeadless() { + + // If you muck up your schema somehow you may want to set this to true for one run. + $force_schema_reinstall = FALSE; + return \Civi\Test::headless() ->installMe(__DIR__) - ->apply(); + ->apply($force_schema_reinstall); } /** diff --git a/src/CRM/CivixBundle/Resources/views/Code/test-headless.php.php b/src/CRM/CivixBundle/Resources/views/Code/test-headless.php.php index e41b0685..5c4035a0 100644 --- a/src/CRM/CivixBundle/Resources/views/Code/test-headless.php.php +++ b/src/CRM/CivixBundle/Resources/views/Code/test-headless.php.php @@ -31,9 +31,13 @@ class extends \PHPUnit_Framework_TestCase implements He public function setUpHeadless() { // Civi\Test has many helpers, like install(), uninstall(), sql(), and sqlFile(). // See: https://github.com/civicrm/org.civicrm.testapalooza/blob/master/civi-test.md + + // If you muck up your schema somehow you may want to set this to true for one run. + $force_schema_reinstall = FALSE; + return \Civi\Test::headless() ->installMe(__DIR__) - ->apply(); + ->apply($force_schema_reinstall); } public function setUp() {