public void RenderVueBlock() { var block = new VueBlock() { ComponentName = "HelloWorld", Message = "Hello EPiServer", SlotContent = new XhtmlString("<p>Hello</p>"), NamedSlots = new Dictionary <string, string> { { "left-banner", "<v-app-vue-test-2 />" } } }; var result = block.RenderComponent(); result.Should().BeEquivalentTo(new { Value = "<v-app-hello-world msg=\"Hello EPiServer\"><p>Hello</p><div slot=\"left-banner\"><v-app-vue-test-2 /></div></v-app-hello-world>" }); }
public void RenderVueBlock() { var block = new VueBlock() { ComponentName = "VueTest", Prop = "abcd", SlotContent = new XhtmlString("<p>Hello</p>"), NamedSlots = new List <IVueBlockNamedSlotContent>() { new VueBlockNamedSlotContent { SlotName = "left-banner", TagName = "v-app-vue-test-2" } } }; var result = block.RenderBlock(); result.Should().BeEquivalentTo(new { Value = "<v-app-vue-test prop=\"abcd\"><p>Hello</p><v-app-vue-test-2 slot=\"left-banner\"></v-app-vue-test-2></v-app-vue-test>" }); }