~ubuntu-branches/ubuntu/raring/maas/raring-updates

« back to all changes in this revision

Viewing changes to src/maasserver/static/jslibs/yui/3.4.1/tests/loader/tests/server/index.html

  • Committer: Package Import Robot
  • Author(s): Andres Rodriguez
  • Date: 2012-07-03 17:42:37 UTC
  • mfrom: (1.1.13)
  • Revision ID: package-import@ubuntu.com-20120703174237-p8l0keuuznfg721k
Tags: 0.1+bzr709+dfsg-0ubuntu1
* New Upstream release
* debian/control:
  - Depends on python-celery, python-tempita, libjs-yui3-{full,min},
    libjs-raphael
* debian/maas.install:
  - Install apiclient, celeryconfig.py, maas-import-pxe-files, preseeds_v2.
  - Update to install various files from chroot, rather tha manually copy
    them from the source.
* debian/maas.links: symlink celeryconfig.py
* debian/maas.maas-celery.upstart: Add job.
* debian/rules:
  - Install celery upstart job.
  - Do not install jslibs as packages are now used.
  - Drop copying of maas_local_settings_sample.py as source now ships
    a maas_local_settings.py
* debian/patches:
  - 04-maas-http-fix.patch: Drop. Merged upstream.
  - 01-fix-database-settings.patch: Refreshed.
  - 99_enums_js.patch: Added until creation of enum.js / build process
    is fixed.
* debian/maas.postinst: Update bzr version to correctly handle upgrades.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<!doctype html>
2
 
<html>
3
 
<head>
4
 
    <title>Generated test runner</title>
5
 
    <style>
6
 
        #info {
7
 
            position: absolute;
8
 
            right: 50px;
9
 
            top: 50px;
10
 
            border: 1px solid black;
11
 
            background-color: #ccc;
12
 
        }
13
 
        iframe {
14
 
            width: 575px;
15
 
            height: 85px;
16
 
            border: 1px dashed black;
17
 
        }
18
 
    </style>
19
 
</head>
20
 
<body class="yui3-skin-sam">
21
 
<h1 id="results">Calculating</h1>
22
 
<div id="info">
23
 
<p>This test will take around 6 minutes when fully run.</p>
24
 
</div>
25
 
<pre id="note"></pre>
26
 
<div id="log"></div>
27
 
 
28
 
<script src="/build/yui/yui.js"></script>
29
 
<script src="generated.js"></script>
30
 
<script>
31
 
 
32
 
//gen_tests = ['node', 'yql', 'dd', 'combo_node', 'combo_yql', 'combo_dd'];
33
 
//gen_tests = ['node', 'yql', 'dd', 'rls_node', 'rls_yql', 'rls_dd'];
34
 
//gen_tests.reverse();
35
 
 
36
 
var h1 = document.getElementById('results');
37
 
var note = document.getElementById('note');
38
 
var frame;
39
 
var title = 'Prepping (#) tests';
40
 
document.title = h1.innerHTML = title.replace('#', gen_tests.length);
41
 
 
42
 
 
43
 
var log = function() {
44
 
    var str = [];
45
 
    for (var i = 0; i < arguments.length; i++) {
46
 
        str.push(arguments[i]);
47
 
    }
48
 
    note.innerHTML = str.join(' ');
49
 
};
50
 
 
51
 
var results = {},
52
 
    Assert,
53
 
    YUITest;
54
 
 
55
 
var confirmTests = function() {
56
 
    document.body.removeChild(frame);
57
 
    document.title = h1.innerHTML = 'Prep Complete';
58
 
    log('Starting YUI Tests');
59
 
    var s = new YUITest.Suite("Dynamic Use");
60
 
    s.add(new YUITest.Case(cases));
61
 
    YUITest.Runner.subscribe(YUITest.Runner.COMPLETE_EVENT, function() {
62
 
        document.title = h1.innerHTML = 'Tests Complete';
63
 
        var endStamp = (new Date()).getTime();
64
 
        var str = ((endStamp - startStamp) / 1000);
65
 
        log('Tests Complete: ' + str + 'secs');
66
 
    });
67
 
    YUITest.Runner.add(s);
68
 
    YUITest.Runner.run();
69
 
    
70
 
};
71
 
 
72
 
var runTest = function() {
73
 
    var mod = gen_tests.pop();
74
 
    if (mod) {
75
 
        document.title = h1.innerHTML = title.replace('#', gen_tests.length);
76
 
        log('Fetching: ', '/tests/' + mod);
77
 
        if (!frame) {
78
 
            frame = document.createElement('iframe');
79
 
            frame.id = 'frame';
80
 
            document.body.appendChild(frame);
81
 
        }
82
 
        frame.src = '/tests/' + mod;
83
 
    } else {
84
 
        confirmTests();
85
 
    }
86
 
};
87
 
 
88
 
var _yui_result = function(d) {
89
 
    log('Test Completed for', d.name);
90
 
    results[d.name] = d;
91
 
    //setTimeout(function() {
92
 
        runTest();
93
 
    //}, 200);
94
 
};
95
 
 
96
 
var startStamp = (new Date()).getTime();
97
 
 
98
 
/*
99
 
YUI().use('test', function(Y) {
100
 
    YUITest = Y.Test;
101
 
    Assert = Y.Assert;
102
 
    runTest();
103
 
});
104
 
*/
105
 
 
106
 
var YUI_config = {
107
 
    gconfig: true,
108
 
    gfilter: (window.location.search.match(/[?&]filter=([^&]+)/) || [])[1] || 'min'
109
 
};
110
 
 
111
 
 
112
 
YUI({
113
 
    allowRollup: false,
114
 
    logExclude: {Dom: true, Selector: true, Node: true, attribute: true, base: true, event: true, widget: true },    
115
 
    filter: YUI_config.gfilter,
116
 
    modules: {
117
 
        'test-console': {
118
 
            fullpath : '/src/common/tests/assets/test-console.js',
119
 
            requires : ['console-filters'],
120
 
            skinnable: true
121
 
        },
122
 
 
123
 
        'skin-sam-test-console': {
124
 
            fullpath: '/src/common/tests/assets/test-console.css',
125
 
            type    : 'css'
126
 
        }
127
 
        
128
 
    }
129
 
}).use('test-console', 'test', function(Y) {
130
 
    YUITest = Y.Test;
131
 
    Assert = Y.Assert;
132
 
    runTest();
133
 
});
134
 
 
135
 
 
136
 
 
137
 
</script>
138
 
</body>
139
 
</html>