Skip to content

Commit

Permalink
check if package gets uninstalled
Browse files Browse the repository at this point in the history
  • Loading branch information
happyDemon committed Oct 21, 2019
1 parent c4e88ab commit 01aa982
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/IntegratedTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,14 @@ public function test_removing_package()
Artisan::call('packager:remove', ['vendor' => 'MyVendor', 'name' => 'MyPackage', '--no-interaction' => true]);
$this->seeInConsoleOutput('Package removed successfully!');
}

public function test_new_package_is_uninstalled()
{
Artisan::call('packager:new', ['vendor' => 'MyVendor', 'name' => 'MyPackage']);
Artisan::call('packager:remove', ['vendor' => 'MyVendor', 'name' => 'MyPackage', '--no-interaction' => true]);

$composer = file_get_contents(base_path('composer.json'));

$this->assertStringNotContainsString('MyVendor/MyPackage', $composer);
}
}

0 comments on commit 01aa982

Please sign in to comment.