@@ -9,8 +9,8 @@ module.exports = {
9
9
browser
10
10
. url ( 'http://localhost:8080/composables/' )
11
11
. waitForElementVisible ( '#app' , 1000 )
12
- . assert . count ( 'li' , 2 )
13
- . assert . count ( 'li a' , 2 )
12
+ . assert . count ( 'li' , 4 )
13
+ . assert . count ( 'li a' , 4 )
14
14
. assert . containsText ( '.view' , 'Home' )
15
15
16
16
. click ( 'li:nth-child(2) a' )
@@ -23,6 +23,23 @@ module.exports = {
23
23
. click ( 'button#nav' )
24
24
. assert . containsText ( '#fullpath' , '/?n=1' )
25
25
26
+ . end ( )
27
+ } ,
28
+
29
+ 'useLink()' : function ( browser ) {
30
+ browser
31
+ . url ( 'http://localhost:8080/composables/' )
32
+ . waitForElementVisible ( '#app' , 1000 )
33
+ . assert . containsText ( '.view' , 'Home' )
34
+
35
+ . assert . containsText ( '#nested-active' , '/composables/nested: false, false' )
36
+ . click ( 'li:nth-child(3) a' )
37
+ . assert . containsText ( '#nested-active' , '/composables/nested: true, true' )
38
+ . click ( 'li:nth-child(4) a' )
39
+ . assert . containsText ( '#nested-active' , '/composables/nested: true, false' )
40
+ . click ( '#nested-active' )
41
+ . assert . containsText ( '#nested-active' , '/composables/nested: true, true' )
42
+
26
43
. end ( )
27
44
}
28
45
0 commit comments