Skip to content

Commit 50a7b66

Browse files
Adjust Breaking BlocksClients tests
1 parent f5db148 commit 50a7b66

File tree

1 file changed

+7
-51
lines changed

1 file changed

+7
-51
lines changed

Test/Notion.IntegrationTests/IBlocksClientTests.cs renamed to Test/Notion.IntegrationTests/BlocksClientTests.cs

Lines changed: 7 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -188,12 +188,13 @@ private static IEnumerable<object[]> BlockData()
188188
},
189189
new object[]
190190
{
191-
new DividerBlock { Divider = new DividerBlock.Data() }, new DividerUpdateBlock(), new Action<IBlock>(
192-
block =>
193-
{
194-
Assert.NotNull(block);
195-
_ = Assert.IsType<DividerBlock>(block);
196-
})
191+
new DividerBlock { Divider = new DividerBlock.Data() },
192+
new DividerUpdateBlock(),
193+
new Action<IBlock, INotionClient>((block, client) =>
194+
{
195+
Assert.NotNull(block);
196+
_ = Assert.IsType<DividerBlock>(block);
197+
})
197198
},
198199
new object[]
199200
{
@@ -354,51 +355,6 @@ private static IEnumerable<object[]> BlockData()
354355
})
355356
},
356357
new object[]
357-
{
358-
new TemplateBlock
359-
{
360-
Template = new TemplateBlock.Data
361-
{
362-
RichText = new List<RichTextBase>
363-
{
364-
new RichTextText { Text = new Text { Content = "Test Template" } }
365-
},
366-
Children = new List<ITemplateChildrenBlock>
367-
{
368-
new EmbedBlock
369-
{
370-
Embed = new EmbedBlock.Info
371-
{
372-
Url
373-
= "https://zephoria.com/wp-content/uploads/2014/08/online-community.jpg"
374-
}
375-
}
376-
}
377-
}
378-
},
379-
new TemplateUpdateBlock
380-
{
381-
Template = new TemplateUpdateBlock.Info
382-
{
383-
RichText = new List<RichTextBaseInput>
384-
{
385-
new RichTextTextInput { Text = new Text { Content = "Test Template 2" } }
386-
}
387-
}
388-
},
389-
new Action<IBlock, INotionClient>((block, client) =>
390-
{
391-
Assert.NotNull(block);
392-
var templateBlock = Assert.IsType<TemplateBlock>(block);
393-
394-
Assert.Single(templateBlock.Template.RichText);
395-
Assert.Null(templateBlock.Template.Children);
396-
397-
Assert.Equal("Test Template 2",
398-
templateBlock.Template.RichText.OfType<RichTextText>().First().Text.Content);
399-
})
400-
},
401-
new object[]
402358
{
403359
new LinkToPageBlock
404360
{

0 commit comments

Comments
 (0)