@@ -146,6 +146,16 @@ describe("draggable.vue when initialized with list", () => {
146
146
}
147
147
)
148
148
149
+ it ( "computes indexes" , async ( ) => {
150
+ await Vue . nextTick ( ) ;
151
+ //To be altered
152
+ expect ( vm . visibleIndexes ) . toEqual ( [ - 1 , 0 , 1 , 2 , - 1 ] ) ;
153
+ } ) ;
154
+
155
+ it ( "set realList" , ( ) => {
156
+ expect ( vm . realList ) . toEqual ( [ "a" , "b" , "c" ] ) ;
157
+ } ) ;
158
+
149
159
describe ( "when using component as tag" , ( ) => {
150
160
beforeEach ( ( ) => {
151
161
input = jest . fn ( ) ;
@@ -560,12 +570,16 @@ describe("draggable.vue when initialized with value", () => {
560
570
element = wrapper . element ;
561
571
} ) ;
562
572
563
- it ( "computes indexes" , async ( ) => {
573
+ it ( "computes indexes" , async ( ) => {
564
574
await Vue . nextTick ( ) ;
565
575
expect ( vm . visibleIndexes ) . toEqual ( [ 0 , 1 , 2 ] ) ;
566
576
} ) ;
567
577
568
- it ( "transition mode should be false" , async ( ) => {
578
+ it ( "set realList" , ( ) => {
579
+ expect ( vm . realList ) . toEqual ( [ "a" , "b" , "c" ] ) ;
580
+ } ) ;
581
+
582
+ it ( "transition mode should be false" , ( ) => {
569
583
expect ( vm . transitionMode ) . toBe ( false ) ;
570
584
} ) ;
571
585
0 commit comments