@@ -31,15 +31,15 @@ describe('Alert component', () => {
31
31
store . dispatch ( 'setAlert' , new Alert ( errorMessage , null , 'error' ) )
32
32
} )
33
33
cy
34
- . get ( '.v-alert ' )
34
+ . get ( '.v-snack ' )
35
35
. should ( 'contain' , errorMessage )
36
36
} )
37
37
it ( 'Uses the right color for success' , ( ) => {
38
38
cy . visit ( '/#/' )
39
39
cy . get ( '.c-header' ) . should ( 'exist' )
40
40
getStore ( ) . then ( store => {
41
41
cy . wrap ( store ) . invoke ( 'commit' , 'SET_ALERT' , new Alert ( 'An alert' , null , 'success' ) )
42
- cy . get ( '.v-alert ' ) . then ( $alertElements => {
42
+ cy . get ( '.v-snack ' ) . then ( $alertElements => {
43
43
const backgroundColor = window . getComputedStyle ( $alertElements [ 0 ] ) [ 'background-color' ]
44
44
expect ( backgroundColor ) . to . not . equal ( COLOR_BLACK )
45
45
expect ( backgroundColor ) . to . not . equal ( COLOR_WHITE )
@@ -52,7 +52,7 @@ describe('Alert component', () => {
52
52
cy . get ( '.c-header' ) . should ( 'exist' )
53
53
getStore ( ) . then ( store => {
54
54
cy . wrap ( store ) . invoke ( 'commit' , 'SET_ALERT' , new Alert ( 'An alert' , null , 'warning' ) )
55
- cy . get ( '.v-alert ' ) . then ( $alertElements => {
55
+ cy . get ( '.v-snack ' ) . then ( $alertElements => {
56
56
const backgroundColor = window . getComputedStyle ( $alertElements [ 0 ] ) [ 'background-color' ]
57
57
expect ( backgroundColor ) . to . not . equal ( COLOR_BLACK )
58
58
expect ( backgroundColor ) . to . not . equal ( COLOR_WHITE )
@@ -65,7 +65,7 @@ describe('Alert component', () => {
65
65
cy . get ( '.c-header' ) . should ( 'exist' )
66
66
getStore ( ) . then ( store => {
67
67
cy . wrap ( store ) . invoke ( 'commit' , 'SET_ALERT' , new Alert ( 'An alert' , null , 'error' ) )
68
- cy . get ( '.v-alert ' ) . then ( $alertElements => {
68
+ cy . get ( '.v-snack ' ) . then ( $alertElements => {
69
69
const backgroundColor = window . getComputedStyle ( $alertElements [ 0 ] ) [ 'background-color' ]
70
70
expect ( backgroundColor ) . to . not . equal ( COLOR_BLACK )
71
71
expect ( backgroundColor ) . to . not . equal ( COLOR_WHITE )
@@ -81,14 +81,14 @@ describe('Alert component', () => {
81
81
store . dispatch ( 'setAlert' , new Alert ( errorMessage , null , 'error' ) )
82
82
} )
83
83
cy
84
- . get ( '.v-alert ' )
84
+ . get ( '.v-snack ' )
85
85
. should ( 'contain' , errorMessage )
86
86
cy
87
- . get ( '.v-alert ' )
87
+ . get ( '.v-snack ' )
88
88
. get ( 'button' )
89
89
. click ( { force : true , multiple : true } )
90
90
cy
91
- . get ( '.v-alert ' )
91
+ . get ( '.v-snack--active ' )
92
92
. should ( 'not.exist' )
93
93
getStore ( ) . then ( store => {
94
94
expect ( store . state . alert ) . to . equal ( null )
0 commit comments