Last modified: 2014-02-12 23:53:57 UTC
Were severely lacking them in this extension.
Examples of things to test: In phpunit? * run some known user-agent strings etc through the magic breakdown to confirm they bring up the settings we expect In ...... some sort of client-side environment? * masquerade as particular clients and ensure that you actually get the expected layout times * masquerade as a web client that remembers cookies and confirm that clicking through the various 'view in desktop', 'view in mobile', etc links act as expected
Basic unit test support has been added in r96938. Now it's time to add some meaningful tests simular to what Brion mentioned in Comment 1.
Seeing this: https://www.mediawiki.org/wiki/Extension_talk:MobileFrontend#Issues_with_MobileFrontend_and_possible_rewrite_11940 I thought some unit tests might now be useful. This diff: http://jonrobson.me.uk/mediawiki/MobileFrontendTests.diff suggests a possible test suite using qunit and suggest some tests to get started for opensearch.js and application.js. I also have some tests for the beta_ code (not attached) that I am still working on. To use run make remotes then navigate to tests/client/index.html in your localhost (the tests to do with cookies will not run off a file uri)
Javascript tests were adding in r111741
(In reply to comment #2) > Basic unit test support has been added in r96938. Now it's time to add some > meaningful tests simular to what Brion mentioned in Comment 1. s/simular/similar