Skip to content

Commit

Permalink
Fixing tests, removed a return; where it should not be and corrected …
Browse files Browse the repository at this point in the history
…an assert.
  • Loading branch information
Florian Krämer committed Feb 5, 2014
1 parent 940bfa5 commit 2095306
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2 deletions.
1 change: 1 addition & 0 deletions Lib/CakeMigration.php
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,7 @@ public function __construct($options = array()) {
}

$allowed = array('connection', 'callback');

foreach ($allowed as $variable) {
if (!empty($options[$variable])) {
$this->{$variable} = $options[$variable];
Expand Down
1 change: 0 additions & 1 deletion Test/Case/Console/Command/MigrationShellTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,6 @@ public function testRun() {
'callback' => $this->Shell,
'version' => 0,
'direction' => 'down',
'reset' => true,
'dry' => false,
'precheck' => null)));
$this->Shell->args = array('reset');
Expand Down
2 changes: 1 addition & 1 deletion Test/Case/Lib/MigrationVersionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ public function testRun() {
$Version->expects($this->at(3))->method('setVersion')->with(4, 'mocks', true);

$this->assertTrue($Version->run(array('direction' => 'up', 'type' => 'mocks')));
return;

// direction => down
$Version->expects($this->at(0))->method('getVersion')->will($this->returnValue(4));
$Version->expects($this->at(1))->method('getMapping')->will($this->returnValue($this->_mapping(1, 4)));
Expand Down

0 comments on commit 2095306

Please sign in to comment.