1
0
Fork 0

Fix tests breaking on a api version bump

Make generic plugins work with many API versions as opposed to just 1.0.0.
pull/4124/head
nevvermind 2015-06-09 15:27:11 +01:00
parent 2051d74774
commit 58ded13eb9
4 changed files with 3 additions and 21 deletions

View File

@ -7,6 +7,6 @@
"class": "Installer\\Plugin" "class": "Installer\\Plugin"
}, },
"require": { "require": {
"composer-plugin-api": "1.0.0" "composer-plugin-api": "*"
} }
} }

View File

@ -7,6 +7,6 @@
"class": "Installer\\Plugin2" "class": "Installer\\Plugin2"
}, },
"require": { "require": {
"composer-plugin-api": "1.0.0" "composer-plugin-api": "*"
} }
} }

View File

@ -7,6 +7,6 @@
"class": "Installer\\Plugin2" "class": "Installer\\Plugin2"
}, },
"require": { "require": {
"composer-plugin-api": "1.0.0" "composer-plugin-api": "*"
} }
} }

View File

@ -249,24 +249,6 @@ class PluginInstallerTest extends TestCase
$this->pm->loadInstalledPlugins(); $this->pm->loadInstalledPlugins();
} }
public function testExactPluginVersionStyleAreRegisteredCorrectly()
{
$pluginsWithFixedAPIVersions = array(
$this->packages[0],
$this->packages[1],
$this->packages[2],
);
$this->setPluginApiVersionWithPlugins('1.0.0', $pluginsWithFixedAPIVersions);
$this->assertCount(3, $this->pm->getPlugins());
$this->setPluginApiVersionWithPlugins('1.0.1', $pluginsWithFixedAPIVersions);
$this->assertCount(0, $this->pm->getPlugins());
$this->setPluginApiVersionWithPlugins('2.0.0-dev', $pluginsWithFixedAPIVersions);
$this->assertCount(0, $this->pm->getPlugins());
}
public function testStarPluginVersionWorksWithAnyAPIVersion() public function testStarPluginVersionWorksWithAnyAPIVersion()
{ {
$starVersionPlugin = array($this->packages[4]); $starVersionPlugin = array($this->packages[4]);