Dotclear

source: tests/functional/lib/jasmine-jquery-bootstrap.js @ 1724:4cc223c99439

Revision 1724:4cc223c99439, 591 bytes checked in by Nicolas <nikrou77@…>, 12 years ago (diff)

[Tests] Add tests for media uploader
Refactoring of _media.js : put all code in a jquery plugin to make
it easy to test and to avoid polluting global namespace.
Use same jquery for tests and for admin

Need to add more tests for media uploader
Fix indentation for all js

Line 
1(function() {
2     jasmine.getFixtures().fixturesPath = 'fixtures';
3     jasmine.getStyleFixtures().fixturesPath = '../../admin/style';
4
5     var jasmineEnv = jasmine.getEnv();
6     jasmineEnv.updateInterval = 1000;
7
8     var htmlReporter = new jasmine.HtmlReporter();
9
10     jasmineEnv.addReporter(htmlReporter);
11
12     jasmineEnv.specFilter = function(spec) {
13          return htmlReporter.specFilter(spec);
14     };
15
16     var currentWindowOnload = window.onload;
17
18     window.onload = function() {
19          if (currentWindowOnload) {
20               currentWindowOnload();
21          }
22          execJasmine();
23     };
24
25     function execJasmine() {
26          jasmineEnv.execute();
27     }
28
29})();
Note: See TracBrowser for help on using the repository browser.

Sites map