AppSuite:Test basics: Difference between revisions

From Open-Xchange
No edit summary
No edit summary
Line 1: Line 1:
Lessons learned painfully while doing testing:
Lessons learned painfully while doing testing:
* PhantomJS thinks it is a touch device.
* PhantomJS thinks it is a touch device (Modernizr.touch === true)
* Almost no CSS is loaded. Don't rely on classes like "hidden" (bootstrap class)
* Don't clear <body> (e.g. $(document.body).empty()). UI is not robust against that.
* The browser window is elastic. It has no fixed size. Usually affects scrolling tests.
* If weird things happen, try to check if your app/window/node is really still in the DOM.
* HTML fixtures cannot be loaded (don't know why yet); just rename your files to *.txt
* Please mind that your fake server only works inside "description" (not across specs)
* PhantomJS fails at: Date.parse("2012-01-01"); (see https://code.google.com/p/phantomjs/issues/detail?id=267#c2)


[[Category:UI]]
[[Category:UI]]

Revision as of 14:08, 2 December 2013

Lessons learned painfully while doing testing:

  • PhantomJS thinks it is a touch device (Modernizr.touch === true)
  • Almost no CSS is loaded. Don't rely on classes like "hidden" (bootstrap class)
  • Don't clear <body> (e.g. $(document.body).empty()). UI is not robust against that.
  • The browser window is elastic. It has no fixed size. Usually affects scrolling tests.
  • If weird things happen, try to check if your app/window/node is really still in the DOM.
  • HTML fixtures cannot be loaded (don't know why yet); just rename your files to *.txt
  • Please mind that your fake server only works inside "description" (not across specs)
  • PhantomJS fails at: Date.parse("2012-01-01"); (see https://code.google.com/p/phantomjs/issues/detail?id=267#c2)