| Conditions | 2 |
| Paths | 2 |
| Total Lines | 11 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 11 | public function run($request = null) |
||
| 12 | { |
||
| 13 | if (!DataObject::get_one('ZonedShippingMethod')) { |
||
| 14 | $factory = Injector::inst()->create('FixtureFactory'); |
||
| 15 | $fixture = new YamlFixture('silvershop-shipping/tests/fixtures/ZonedShippingMethod.yml'); |
||
| 16 | $fixture->writeInto($factory); |
||
| 17 | DB::alteration_message('Created zoned shipping methods', 'created'); |
||
| 18 | } else { |
||
| 19 | DB::alteration_message('Some zoned shipping methods already exist. None were created.'); |
||
| 20 | } |
||
| 21 | } |
||
| 22 | } |
||
| 37 |