Skip to content
This repository
Browse code

Fix failing tests.

* New properties on view caused fails in Debugger.
* Element cache keys have changed with the new refactoring.
  • Loading branch information...
commit 369bbcc964741a26139290683dc075e8b9d357f8 1 parent 2967a4d
Mark Story authored July 07, 2012
1  lib/Cake/Test/Case/Utility/DebuggerTest.php
@@ -327,6 +327,7 @@ public function testExportVar() {
327 327
 	request => object(CakeRequest) {}
328 328
 	response => object(CakeResponse) {}
329 329
 	elementCache => 'default'
  330
+	elementCacheSettings => array()
330 331
 	int => (int) 2
331 332
 	float => (float) 1.333
332 333
 }
8  lib/Cake/Test/Case/View/ViewTest.php
@@ -661,7 +661,7 @@ public function testElement() {
661 661
  *
662 662
  */
663 663
 	public function testElementCallbacks() {
664  
-		$this->getMock('HtmlHelper', array(), array($this->View), 'ElementCallbackMockHtmlHelper');
  664
+		$this->getMock('Helper', array(), array($this->View), 'ElementCallbackMockHtmlHelper');
665 665
 		$this->View->helpers = array('ElementCallbackMockHtml');
666 666
 		$this->View->loadHelpers();
667 667
 
@@ -725,13 +725,13 @@ public function testElementCache() {
725 725
 		$expected = 'this is the test element';
726 726
 		$this->assertEquals($expected, $result);
727 727
 
728  
-		$result = Cache::read('element__test_element_cache', 'test_view');
  728
+		$result = Cache::read('element__test_element_cache_callbacks', 'test_view');
729 729
 		$this->assertEquals($expected, $result);
730 730
 
731 731
 		$result = $View->element('test_element', array('param' => 'one', 'foo' => 'two'), array('cache' => true));
732 732
 		$this->assertEquals($expected, $result);
733 733
 
734  
-		$result = Cache::read('element__test_element_cache_param_foo', 'test_view');
  734
+		$result = Cache::read('element__test_element_cache_callbacks_param_foo', 'test_view');
735 735
 		$this->assertEquals($expected, $result);
736 736
 
737 737
 		$result = $View->element('test_element', array(
@@ -750,7 +750,7 @@ public function testElementCache() {
750 750
 		), array(
751 751
 			'cache' => array('config' => 'test_view'),
752 752
 		));
753  
-		$result = Cache::read('element__test_element_cache_param_foo', 'test_view');
  753
+		$result = Cache::read('element__test_element_cache_callbacks_param_foo', 'test_view');
754 754
 		$this->assertEquals($expected, $result);
755 755
 
756 756
 		Cache::clear(true, 'test_view');

0 notes on commit 369bbcc

Please sign in to comment.
Something went wrong with that request. Please try again.