Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Examples of JavaScript RIAs with unit tests

Can anyone give me examples of large-scale JS apps (including AJAX, different UI widgets, and a sophisticated architecture) with unit tests?

I'm not talking about Selenium tests here, just plain ol' stupid unit tests using mocks, decent result reporting and such.


Not sure why people voted to close, or downvoted the question. Maybe a comment would be nice. Seriously, I've been trying hard to find unit tested web apps, since I'm having a hard time building mocks and I wonder if it's even possible with reasonable effort. It made me think about the benefits of unit tests on widgets as compared to Selenium tests. People are babbling a lot about unit tests in theory but evidently nobody actually has done it in JS-RIAs. Or have they?

like image 333
user123444555621 Avatar asked Nov 25 '11 07:11

user123444555621


People also ask

What is unit testing in JavaScript with example?

JavaScript Unit Testing is a method where JavaScript test code is written for a web page or web application module. It is then combined with HTML as an inline event handler and executed in the browser to test if all functionalities are working as desired. These unit tests are then organized in the test suite.

Can JUnit be used for JavaScript?

Because the JavaScript tests are JUnit tests they “Just work” with existing JUnit tools like Eclipse and as part of your build with ant/maven. The Eclipse UI shows every test function and a useful error trace (Line numbers only work with Nashorn).

Can we use cypress for unit testing?

Further, using Cypress will be easy if you're familiar with writing tests in JavaScript. Cypress covers two major styles of writing tests: end-to-end testing and unit testing.

What are the challenges in JavaScript unit testing?

Challenges in JavaScript Unit Testing You can understand some system actions with other languages, but this is not the case with JavaScript. Some JavaScript are written for a web application may have multiple dependencies. JavaScript is good to use in combination with HTML and CSS rather than on the web.


2 Answers

Personally I like Qooxdoo, check it out for your self and see if this is what you want

http://qooxdoo.org/demo#real-life_examples

like image 107
cuzzea Avatar answered Oct 18 '22 22:10

cuzzea


This is one good tool: http://www.uize.com/

like image 37
Sudhir Bastakoti Avatar answered Oct 18 '22 20:10

Sudhir Bastakoti