@@ -243,7 +243,7 @@ public function testResponseContainsHeaders()
243
243
244
244
$ this ->assertNotEmpty ($ response ->getHeaders ());
245
245
}
246
-
246
+
247
247
/**
248
248
* Test redirect URL is set in response
249
249
* if request is redirected.
@@ -310,7 +310,7 @@ public function testCaptureRequestSavesFileToLocalDisk()
310
310
$ response = $ client ->getMessageFactory ()->createResponse ();
311
311
312
312
$ request ->setMethod ('GET ' );
313
- $ request ->setUrl ('http://jonnyw.kiwi/tests/test-console-error .php ' );
313
+ $ request ->setUrl ('http://jonnyw.kiwi/tests/test-capture .php ' );
314
314
$ request ->setOutputFile ($ file );
315
315
316
316
$ client ->send ($ request , $ response );
@@ -750,6 +750,33 @@ public function testDebugLogsDebugInfoToClientLog()
750
750
$ this ->assertContains ('[DEBUG] ' , $ client ->getLog ());
751
751
}
752
752
753
+ /**
754
+ * Test test can set page
755
+ * background color
756
+ *
757
+ * @access public
758
+ * @return void
759
+ */
760
+ public function testCanSetPageBackgroundColor ()
761
+ {
762
+ $ this ->filename = 'test.jpg ' ;
763
+ $ file = ($ this ->directory . '/ ' . $ this ->filename );
764
+
765
+ $ client = $ this ->getClient ();
766
+
767
+ $ request = $ client ->getMessageFactory ()->createCaptureRequest ();
768
+ $ response = $ client ->getMessageFactory ()->createResponse ();
769
+
770
+ $ request ->setMethod ('GET ' );
771
+ $ request ->setUrl ('http://jonnyw.kiwi/tests/test-capture.php ' );
772
+ $ request ->setBodyStyles (array ('backgroundColor ' => 'red ' ));
773
+ $ request ->setOutputFile ($ file );
774
+
775
+ $ client ->send ($ request , $ response );
776
+
777
+ $ this ->assertContains ('body style="background-color: red;" ' , $ response ->getContent ());
778
+ }
779
+
753
780
/** +++++++++++++++++++++++++++++++++++ **/
754
781
/** ++++++++++ TEST ENTITIES ++++++++++ **/
755
782
/** +++++++++++++++++++++++++++++++++++ **/
0 commit comments