File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed
Test/Notion.IntegrationTests Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change @@ -398,6 +398,36 @@ private static IEnumerable<object[]> BlockData()
398398
399399 Assert . Equal ( "Test 2" , quoteBlock . Quote . Text . OfType < RichTextText > ( ) . First ( ) . Text . Content ) ;
400400 } )
401+ } ,
402+ new object [ ]
403+ {
404+ new ImageBlock ( ) {
405+ Image = new ExternalFile
406+ {
407+ External = new ExternalFile . Info
408+ {
409+ Url = "https://zephoria.com/wp-content/uploads/2014/08/online-community.jpg"
410+ }
411+ }
412+ } ,
413+ new ImageUpdateBlock ( )
414+ {
415+ Image = new ExternalFileInput
416+ {
417+ External = new ExternalFileInput . Data
418+ {
419+ Url = "https://www.iaspaper.net/wp-content/uploads/2017/09/TNEA-Online-Application.jpg"
420+ }
421+ }
422+ } ,
423+ new Action < IBlock > ( block =>
424+ {
425+ Assert . NotNull ( block ) ;
426+ var imageBlock = Assert . IsType < ImageBlock > ( block ) ;
427+ var imageFile = Assert . IsType < ExternalFile > ( imageBlock . Image ) ;
428+
429+ Assert . Equal ( "https://www.iaspaper.net/wp-content/uploads/2017/09/TNEA-Online-Application.jpg" , imageFile . External . Url ) ;
430+ } )
401431 }
402432 } ;
403433 }
You can’t perform that action at this time.
0 commit comments