| <!DOCTYPE html> |
| <html> |
| <head> |
| </head> |
| <body> |
| <script src="/js-test-resources/js-test.js"></script> |
| <script> |
| description("This tests that 'ApplicationCache' methods throw exceptions with reasonable messages."); |
| |
| var cache = window.applicationCache; |
| shouldThrow('cache.update()', '"InvalidStateError: Failed to execute \'update\' on \'ApplicationCache\': there is no application cache to update."'); |
| shouldThrow('cache.swapCache()', '"InvalidStateError: Failed to execute \'swapCache\' on \'ApplicationCache\': there is no newer application cache to swap to."'); |
| </script> |
| </body> |
| </html> |