| OLD | NEW |
| 1 description("This test checks the implementation of getting the document.title a
ttribute."); | 1 description("This test checks the implementation of getting the document.title a
ttribute."); |
| 2 | 2 |
| 3 debug('Test with no title set'); | 3 debug('Test with no title set'); |
| 4 shouldBeEqualToString("document.title", ""); | 4 shouldBeEqualToString("document.title", ""); |
| 5 | 5 |
| 6 debug('Test with empty title'); | 6 debug('Test with empty title'); |
| 7 document.title = ""; | 7 document.title = ""; |
| 8 shouldBeEqualToString("document.title",""); | 8 shouldBeEqualToString("document.title",""); |
| 9 | 9 |
| 10 debug('Test with only whitespace'); | 10 debug('Test with only whitespace'); |
| 11 document.title = "\t\n\r \r \t\n\n"; | 11 document.title = "\t\n\r \r \t\n\n"; |
| 12 shouldBeEqualToString("document.title",""); | 12 shouldBeEqualToString("document.title",""); |
| 13 | 13 |
| 14 debug('Test with no whitespace'); | 14 debug('Test with no whitespace'); |
| 15 document.title = "nowhitespacetitle"; | 15 document.title = "nowhitespacetitle"; |
| 16 shouldBeEqualToString("document.title","nowhitespacetitle"); | 16 shouldBeEqualToString("document.title","nowhitespacetitle"); |
| 17 | 17 |
| 18 debug('Test with whitespace'); | 18 debug('Test with whitespace'); |
| 19 document.title = "\u0009\u000aone\u000b\u000cspace\u000d\u0020"; | 19 document.title = "\u0009\u000aone\u000b\u000cspace\u000d\u0020"; |
| 20 shouldBeEqualToString("document.title","one space"); | 20 shouldBeEqualToString("document.title","one\u000b space"); |
| 21 | 21 |
| 22 debug('Test with various whitespace lengths and fields'); | 22 debug('Test with various whitespace lengths and fields'); |
| 23 document.title = " lots of \r whitespace and \n\n\n \t newlines \t"; | 23 document.title = " lots of \r whitespace and \n\n\n \t newlines \t"; |
| 24 shouldBeEqualToString("document.title", "lots of whitespace and newlines"); | 24 shouldBeEqualToString("document.title", "lots of whitespace and newlines"); |
| 25 | 25 |
| 26 debug('Test with various length strings'); | 26 debug('Test with various length strings'); |
| OLD | NEW |