Skip to content

Commit

Permalink
Fixing tests from CommandListShell when run on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
lorenzo committed Jun 21, 2011
1 parent d54f8dc commit 552bd82
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions lib/Cake/Console/Command/CommandListShell.php
Expand Up @@ -201,6 +201,7 @@ protected function _asXml($shellList) {
$shell->addAttribute('provider', $source);
$shell->addAttribute('help', $callable . ' -h');
}
$this->stdout->outputAs(ConsoleOutput::RAW);
$this->out($shells->saveXml());
}

Expand Down
10 changes: 5 additions & 5 deletions lib/Cake/Test/Case/Console/Command/CommandListShellTest.php
Expand Up @@ -122,16 +122,16 @@ public function testSortPlugin() {

$output = $this->Shell->stdout->output;

$expected = "/\[.*App.*\]\n[ ]+sample/";
$expected = "/\[.*App.*\]\\v*[ ]+sample/";
$this->assertPattern($expected, $output);

$expected = "/\[.*TestPluginTwo.*\]\n[ ]+example, welcome/";
$expected = "/\[.*TestPluginTwo.*\]\\v*[ ]+example, welcome/";
$this->assertPattern($expected, $output);

$expected = "/\[.*TestPlugin.*\]\n[ ]+example/";
$expected = "/\[.*TestPlugin.*\]\\v*[ ]+example/";
$this->assertPattern($expected, $output);

$expected = "/\[.*Core.*\]\n[ ]+acl, api, bake, command_list, console, i18n, schema, testsuite/";
$expected = "/\[.*Core.*\]\\v*[ ]+acl, api, bake, command_list, console, i18n, schema, testsuite/";
$this->assertPattern($expected, $output);
}

Expand All @@ -146,7 +146,7 @@ public function testMainXml() {

$output = $this->Shell->stdout->output;

$find = '<shell name="sample" call_as="sample" provider="app" help="sample -h"/>';
$find = '<shell name="sample" call_as="sample" provider="app" help="sample -h"/>';
$this->assertContains($find, $output);

$find = '<shell name="bake" call_as="bake" provider="CORE" help="bake -h"/>';
Expand Down

0 comments on commit 552bd82

Please sign in to comment.