Skip to content

Commit 89f7108

Browse files
committed
added examples
1 parent 093e335 commit 89f7108

File tree

8 files changed

+1522
-0
lines changed

8 files changed

+1522
-0
lines changed

examples/cor-blimey.js

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
2+
function meaningOfLife()
3+
{
4+
var a = 10 * 2 * 2;
5+
var b = 1 + 1;
6+
7+
return a+b;
8+
}
9+
10+
function whatDoYouExpect()
11+
{
12+
return 'SPANISH INQUISITION!';
13+
}

examples/qunit/qunit.css

Lines changed: 155 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,155 @@
1+
/** Font Family and Sizes */
2+
3+
#qunit-tests, #qunit-header, #qunit-banner, #qunit-testrunner-toolbar, #qunit-userAgent, #qunit-testresult {
4+
font-family: "Helvetica Neue Light", "HelveticaNeue-Light", "Helvetica Neue", Calibri, Helvetica, Arial;
5+
}
6+
7+
#qunit-testrunner-toolbar, #qunit-userAgent, #qunit-testresult, #qunit-tests li { font-size: small; }
8+
#qunit-tests { font-size: smaller; }
9+
10+
11+
/** Resets */
12+
13+
#qunit-tests, #qunit-tests ol, #qunit-header, #qunit-banner, #qunit-userAgent, #qunit-testresult {
14+
margin: 0;
15+
padding: 0;
16+
}
17+
18+
19+
/** Header */
20+
21+
#qunit-header {
22+
padding: 0.5em 0 0.5em 1em;
23+
24+
color: #fff;
25+
text-shadow: rgba(0, 0, 0, 0.5) 4px 4px 1px;
26+
background-color: #0d3349;
27+
28+
border-radius: 15px 15px 0 0;
29+
-moz-border-radius: 15px 15px 0 0;
30+
-webkit-border-top-right-radius: 15px;
31+
-webkit-border-top-left-radius: 15px;
32+
}
33+
34+
#qunit-header a {
35+
text-decoration: none;
36+
color: white;
37+
}
38+
39+
#qunit-banner {
40+
height: 5px;
41+
}
42+
43+
#qunit-testrunner-toolbar {
44+
padding: 0em 0 0.5em 2em;
45+
}
46+
47+
#qunit-userAgent {
48+
padding: 0.5em 0 0.5em 2.5em;
49+
background-color: #2b81af;
50+
color: #fff;
51+
text-shadow: rgba(0, 0, 0, 0.5) 2px 2px 1px;
52+
}
53+
54+
55+
/** Tests: Pass/Fail */
56+
57+
#qunit-tests {
58+
list-style-position: inside;
59+
}
60+
61+
#qunit-tests li {
62+
padding: 0.4em 0.5em 0.4em 2.5em;
63+
border-bottom: 1px solid #fff;
64+
list-style-position: inside;
65+
}
66+
67+
#qunit-tests li strong {
68+
cursor: pointer;
69+
}
70+
71+
#qunit-tests ol {
72+
margin-top: 0.5em;
73+
padding: 0.5em;
74+
75+
background-color: #fff;
76+
77+
border-radius: 15px;
78+
-moz-border-radius: 15px;
79+
-webkit-border-radius: 15px;
80+
81+
box-shadow: inset 0px 2px 13px #999;
82+
-moz-box-shadow: inset 0px 2px 13px #999;
83+
-webkit-box-shadow: inset 0px 2px 13px #999;
84+
}
85+
86+
/*** Test Counts */
87+
88+
#qunit-tests b.counts { color: black; }
89+
#qunit-tests b.passed { color: #5E740B; }
90+
#qunit-tests b.failed { color: #710909; }
91+
92+
#qunit-tests li li {
93+
margin: 0.5em;
94+
padding: 0.4em 0.5em 0.4em 0.5em;
95+
background-color: #fff;
96+
border-bottom: none;
97+
list-style-position: inside;
98+
}
99+
100+
/*** Passing Styles */
101+
102+
#qunit-tests li li.pass {
103+
color: #5E740B;
104+
background-color: #fff;
105+
border-left: 26px solid #C6E746;
106+
}
107+
108+
#qunit-tests .pass { color: #528CE0; background-color: #D2E0E6; }
109+
#qunit-tests .pass .test-name { color: #366097; }
110+
111+
#qunit-tests .pass .test-actual,
112+
#qunit-tests .pass .test-expected { color: #999999; }
113+
114+
#qunit-banner.qunit-pass { background-color: #C6E746; }
115+
116+
/*** Failing Styles */
117+
118+
#qunit-tests li li.fail {
119+
color: #710909;
120+
background-color: #fff;
121+
border-left: 26px solid #EE5757;
122+
}
123+
124+
#qunit-tests .fail { color: #000000; background-color: #EE5757; }
125+
#qunit-tests .fail .test-name,
126+
#qunit-tests .fail .module-name { color: #000000; }
127+
128+
#qunit-tests .fail .test-actual { color: #EE5757; }
129+
#qunit-tests .fail .test-expected { color: green; }
130+
131+
#qunit-banner.qunit-fail,
132+
#qunit-testrunner-toolbar { background-color: #EE5757; }
133+
134+
135+
/** Footer */
136+
137+
#qunit-testresult {
138+
padding: 0.5em 0.5em 0.5em 2.5em;
139+
140+
color: #2b81af;
141+
background-color: #D2E0E6;
142+
143+
border-radius: 0 0 15px 15px;
144+
-moz-border-radius: 0 0 15px 15px;
145+
-webkit-border-bottom-right-radius: 15px;
146+
-webkit-border-bottom-left-radius: 15px;
147+
}
148+
149+
/** Fixture */
150+
151+
#qunit-fixture {
152+
position: absolute;
153+
top: -10000px;
154+
left: -10000px;
155+
}

0 commit comments

Comments
 (0)