| @@ 78-87 (lines=10) @@ | ||
| 75 | * Note: Tests experimental API |
|
| 76 | * @internal |
|
| 77 | */ |
|
| 78 | public function testGetResourcePath() |
|
| 79 | { |
|
| 80 | $module = $this->manifest->getModule('moduleb'); |
|
| 81 | $this->assertTrue($module->hasResource('composer.json')); |
|
| 82 | $this->assertFalse($module->hasResource('package.json')); |
|
| 83 | $this->assertEquals( |
|
| 84 | 'moduleb/composer.json', |
|
| 85 | $module->getResourcePath('composer.json') |
|
| 86 | ); |
|
| 87 | } |
|
| 88 | ||
| 89 | /* |
|
| 90 | * Note: Tests experimental API |
|
| @@ 93-101 (lines=9) @@ | ||
| 90 | * Note: Tests experimental API |
|
| 91 | * @internal |
|
| 92 | */ |
|
| 93 | public function testGetResourcePathOnRoot() |
|
| 94 | { |
|
| 95 | $module = $this->manifest->getModule('silverstripe/root-module'); |
|
| 96 | $this->assertTrue($module->hasResource('composer.json')); |
|
| 97 | $this->assertEquals( |
|
| 98 | 'composer.json', |
|
| 99 | $module->getResourcePath('composer.json') |
|
| 100 | ); |
|
| 101 | } |
|
| 102 | } |
|
| 103 | ||