File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -220,6 +220,24 @@ await cut.InvokeAsync(() => input.Instance.OnChange.InvokeAsync(new InputFileCha
220220 btn . InnerHtml . Contains ( "disabled=\" disabled\" " ) ;
221221 }
222222
223+ [ Fact ]
224+ public void ActionButtonTemplate_Ok ( )
225+ {
226+ var cut = Context . RenderComponent < CardUpload < string > > ( pb =>
227+ {
228+ pb . Add ( a => a . DefaultFileList ,
229+ [
230+ new ( ) { FileName = "test.png" }
231+ ] ) ;
232+ pb . Add ( a => a . ActionButtonTemplate , file => pb =>
233+ {
234+ pb . AddMarkupContent ( 0 , "<button class=\" action-button-test\" ></button>" ) ;
235+ } ) ;
236+ } ) ;
237+
238+ cut . Contains ( "action-button-test" ) ;
239+ }
240+
223241 private class MockBrowserFile ( string name = "UploadTestFile" , string contentType = "text" , TimeSpan ? delay = null ) : IBrowserFile
224242 {
225243 public string Name { get ; } = name ;
You can’t perform that action at this time.
0 commit comments