File tree Expand file tree Collapse file tree 1 file changed +23
-0
lines changed
tests/LinkDotNet.Blog.UnitTests/Web/Shared Expand file tree Collapse file tree 1 file changed +23
-0
lines changed Original file line number Diff line number Diff line change @@ -58,4 +58,27 @@ public void ShouldPutIdAndClassOnItems()
58
58
cut . FindAll ( ".some-class" ) . Should ( ) . NotBeEmpty ( ) ;
59
59
cut . FindAll ( "#some-id" ) . Should ( ) . NotBeEmpty ( ) ;
60
60
}
61
+
62
+ [ Fact ]
63
+ public void ShouldIndicateDragAndDropBehavior ( )
64
+ {
65
+ Services . AddScoped ( _ => new Mock < IFileProcessor > ( ) . Object ) ;
66
+ var cut = RenderComponent < UploadFile > ( ) ;
67
+
68
+ cut . Find ( "input" ) . DragEnter ( ) ;
69
+
70
+ cut . Find ( ".can-drop" ) . Should ( ) . NotBeNull ( ) ;
71
+ }
72
+
73
+ [ Fact ]
74
+ public void ShouldRemoveDragAndDropBehaviorWhenOutside ( )
75
+ {
76
+ Services . AddScoped ( _ => new Mock < IFileProcessor > ( ) . Object ) ;
77
+ var cut = RenderComponent < UploadFile > ( ) ;
78
+ cut . Find ( "input" ) . DragEnter ( ) ;
79
+
80
+ cut . Find ( "input" ) . DragLeave ( ) ;
81
+
82
+ cut . FindAll ( ".can-drop" ) . Should ( ) . BeEmpty ( ) ;
83
+ }
61
84
}
You can’t perform that action at this time.
0 commit comments