@@ -8,15 +8,15 @@ $(document).ready(function(){
8
8
if ( 2 > 0 ) {
9
9
isPositive = true ;
10
10
}
11
- equals ( isPositive , __ , 'what is the value of isPositive?' ) ;
11
+ equals ( isPositive , true , 'what is the value of isPositive?' ) ;
12
12
} ) ;
13
13
14
14
test ( "for" , function ( ) {
15
15
var counter = 10 ;
16
16
for ( var i = 1 ; i <= 3 ; i ++ ) {
17
17
counter = counter + i ;
18
18
}
19
- equals ( counter , __ , 'what is the value of counter?' ) ;
19
+ equals ( counter , 16 , 'what is the value of counter?' ) ;
20
20
} ) ;
21
21
22
22
test ( "for in" , function ( ) {
@@ -30,15 +30,15 @@ $(document).ready(function(){
30
30
for ( property_name in person ) {
31
31
result = result + property_name ;
32
32
} ;
33
- equals ( result , __ , 'what is the value of result?' ) ;
33
+ equals ( result , "nameage" , 'what is the value of result?' ) ;
34
34
} ) ;
35
35
36
36
test ( "ternary operator" , function ( ) {
37
37
var fruit = true ? "apple" : "orange" ;
38
- equals ( fruit , __ , 'what is the value of fruit?' ) ;
38
+ equals ( fruit , "apple" , 'what is the value of fruit?' ) ;
39
39
40
40
fruit = false ? "apple" : "orange" ;
41
- equals ( fruit , __ , 'now what is the value of fruit?' ) ;
41
+ equals ( fruit , "orange" , 'now what is the value of fruit?' ) ;
42
42
} ) ;
43
43
44
44
test ( "switch" , function ( ) {
@@ -51,7 +51,7 @@ $(document).ready(function(){
51
51
result = 2 ;
52
52
break ;
53
53
}
54
- equals ( result , __ , 'what is the value of result?' ) ;
54
+ equals ( result , 2 , 'what is the value of result?' ) ;
55
55
} ) ;
56
56
57
57
test ( "switch default case" , function ( ) {
@@ -67,12 +67,12 @@ $(document).ready(function(){
67
67
result = "Merry" ;
68
68
break ;
69
69
}
70
- equals ( result , __ , 'what is the value of result?' ) ;
70
+ equals ( result , "Merry" , 'what is the value of result?' ) ;
71
71
} ) ;
72
72
73
73
test ( "null coallescion" , function ( ) {
74
74
var result = null || "a value" ;
75
- equals ( result , __ , 'what is the value of result?' ) ;
75
+ equals ( result , "a value" , 'what is the value of result?' ) ;
76
76
} ) ;
77
77
78
78
} ) ;
0 commit comments