Skip to content
Permalink
Browse files

Updating test cases with failing tests.

  • Loading branch information...
markstory committed Nov 16, 2010
1 parent 66e6ec7 commit f0ac462775a24e5801ac234bdc10c5485154206c
@@ -65,7 +65,7 @@ function testLoad() {
* @return void
*/
function testLoadWithEnableFalse() {
$result = $this->Components->load('Cookie', array('callbacks' => false));
$result = $this->Components->load('Cookie', array('enabled' => false));
$this->assertType('CookieComponent', $result);
$this->assertType('CookieComponent', $this->Components->Cookie);
@@ -1451,17 +1451,18 @@ function testPluginModel() {
* @return void
*/
function testAjaxLogin() {
App::build(array('views' => array(TEST_CAKE_CORE_INCLUDE_PATH . 'tests' . DS . 'test_app' . DS . 'views'. DS)));
App::build(array(
'views' => array(TEST_CAKE_CORE_INCLUDE_PATH . 'tests' . DS . 'test_app' . DS . 'views'. DS)
));
$_SERVER['HTTP_X_REQUESTED_WITH'] = "XMLHttpRequest";
if (!class_exists('dispatcher')) {
require CAKE . 'dispatcher.php';
}
App::import('Core', 'Dispatcher');
ob_start();
$Dispatcher = new Dispatcher();
$Dispatcher->dispatch('/ajax_auth/add', array('return' => 1));
$Dispatcher->dispatch(new CakeRequest('/ajax_auth/add'), array('return' => 1));
$result = ob_get_clean();
$this->assertEqual("Ajax!\nthis is the test element", str_replace("\r\n", "\n", $result));
unset($_SERVER['HTTP_X_REQUESTED_WITH']);
}
@@ -243,7 +243,8 @@ function testExportVar() {
View::$modelId = NULL
View::$uuids = array
View::$output = false
View::$request = NULL';
View::$request = NULL
View::$elementCache = "default"';
$result = str_replace(array("\t", "\r\n", "\n"), "", strtolower($result));
$expected = str_replace(array("\t", "\r\n", "\n"), "", strtolower($expected));
$this->assertEqual($result, $expected);
@@ -36,6 +36,7 @@ class RssHelperTest extends CakeTestCase {
*/
function setUp() {
parent::setUp();
$controller = null;
$this->View = new View($controller);
$this->Rss = new RssHelper($this->View);
}

0 comments on commit f0ac462

Please sign in to comment.
You can’t perform that action at this time.