-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest9.html
41 lines (33 loc) · 1.19 KB
/
test9.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Test9</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" href="qunit/qunit-1.12.0.css">
</head>
<body>
<div id="qunit"></div>
<div id="qunit-fixture"></div>
<script src="qunit/qunit-1.12.0.js"></script>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<script>
test( "2 asserts", function() {
var $fixture = $( "#qunit-fixture" );
$fixture.append( "<div>hello!</div>" );
equal( $( "div", $fixture ).length, 1, "div added successfully!" );
$fixture.append( "<span>hello!</span>" );
equal( $( "span", $fixture ).length, 1, "span added successfully!" );
});
test( "Appends a div", function() {
var $fixture = $( "#qunit-fixture" );
$fixture.append( "<div>hello!</div>" );
equal( $( "div", $fixture ).length, 1, "div added successfully!" );
});
test( "Appends a span", function() {
var $fixture = $( "#qunit-fixture" );
$fixture.append("<span>hello!</span>" );
equal( $( "span", $fixture ).length, 1, "span added successfully!" );
});
</script>
</body>
</html>