Skip to content

Commit 93c4b1f

Browse files
committed
fix: applied improvements from code review
1 parent 323af67 commit 93c4b1f

9 files changed

Lines changed: 23 additions & 51 deletions

src/WebExpress.WebUI.Test/WebControl/UnitTestControlLink.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,7 @@ public void Add()
236236

237237
Assert.Equal(@"<a class=""wx-link""><i class=""fas fa-star""></i></a>", html1.Trim());
238238
Assert.Equal(@"<a class=""wx-link""><i class=""fas fa-star""></i></a>", html2.Trim());
239+
Assert.Equal(@"<a class=""wx-link""><i class=""fas fa-star""></i></a>", html3.Trim());
239240
Assert.Equal(@"<a class=""wx-link""><i class=""fas fa-star""></i></a>", html4.Trim());
240241
Assert.Equal(@"<a class=""wx-link""><i class=""fas fa-star""></i></a>", html5.Trim());
241242
Assert.Equal(@"<a class=""wx-link""><i class=""fas fa-star""></i></a>", html6.Trim());

src/WebExpress.WebUI.Test/WebControl/UnitTestControlModalRemoteForm.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55
namespace WebExpress.WebUI.Test.WebControl
66
{
77
/// <summary>
8-
/// Tests the modal page control.
8+
/// Tests the remote modal form control.
99
/// </summary>
1010
[Collection("NonParallelTests")]
1111
public class UnitTestControlModalRemoteForm
1212
{
1313
/// <summary>
14-
/// Tests the id property of the modal page control.
14+
/// Tests the id property of the remote modal form control.
1515
/// </summary>
1616
[Theory]
1717
[InlineData(null, @"<div class=""wx-webui-modal-form"" *></div>")]
@@ -33,7 +33,7 @@ public void Id(string id, string expected)
3333
}
3434

3535
/// <summary>
36-
/// Tests the header property of the modal page control.
36+
/// Tests the header property of the remote modal form control.
3737
/// </summary>
3838
[Theory]
3939
[InlineData(null, @"<div class=""wx-webui-modal-form"" data-close-label=""Close"">*</div>")]
@@ -57,7 +57,7 @@ public void Header(string header, string expected)
5757
}
5858

5959
/// <summary>
60-
/// Tests the size property of the modal page control.
60+
/// Tests the size property of the remote modal form control.
6161
/// </summary>
6262
[Theory]
6363
[InlineData(TypeModalSize.Default, @"<div class=""wx-webui-modal-form"" data-close-label=""Close"">*</div>")]
@@ -83,7 +83,7 @@ public void Size(TypeModalSize size, string expected)
8383
}
8484

8585
/// <summary>
86-
/// Tests the uri property of the modal page control.
86+
/// Tests the uri property of the remote modal form control.
8787
/// </summary>
8888
[Theory]
8989
[InlineData(null, @"<div class=""wx-webui-modal-form"" *>*</div>")]
@@ -106,7 +106,7 @@ public void Uri(string uri, string expected)
106106
}
107107

108108
/// <summary>
109-
/// Tests the selector property of the modal page control.
109+
/// Tests the selector property of the remote modal form control.
110110
/// </summary>
111111
[Theory]
112112
[InlineData(null, @"<div class=""wx-webui-modal-form"" *>*</div>")]

src/WebExpress.WebUI.Test/WebControl/UnitTestControlModalRemotePage.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55
namespace WebExpress.WebUI.Test.WebControl
66
{
77
/// <summary>
8-
/// Tests the modal page control.
8+
/// Tests the remote modal page control.
99
/// </summary>
1010
[Collection("NonParallelTests")]
1111
public class UnitTestControlModalRemotePage
1212
{
1313
/// <summary>
14-
/// Tests the id property of the modal page control.
14+
/// Tests the id property of the remote modal page control.
1515
/// </summary>
1616
[Theory]
1717
[InlineData(null, @"<div class=""wx-webui-modal-page"" *></div>")]
@@ -33,7 +33,7 @@ public void Id(string id, string expected)
3333
}
3434

3535
/// <summary>
36-
/// Tests the header property of the modal page control.
36+
/// Tests the header property of the remote modal page control.
3737
/// </summary>
3838
[Theory]
3939
[InlineData(null, @"<div class=""wx-webui-modal-page"" data-close-label=""Close"">*</div>")]
@@ -57,7 +57,7 @@ public void Header(string header, string expected)
5757
}
5858

5959
/// <summary>
60-
/// Tests the size property of the modal page control.
60+
/// Tests the size property of the remote modal page control.
6161
/// </summary>
6262
[Theory]
6363
[InlineData(TypeModalSize.Default, @"<div class=""wx-webui-modal-page"" data-close-label=""Close"">*</div>")]
@@ -83,7 +83,7 @@ public void Size(TypeModalSize size, string expected)
8383
}
8484

8585
/// <summary>
86-
/// Tests the uri property of the modal page control.
86+
/// Tests the uri property of the remote modal page control.
8787
/// </summary>
8888
[Theory]
8989
[InlineData(null, @"<div class=""wx-webui-modal-page"" *>*</div>")]
@@ -106,7 +106,7 @@ public void Uri(string uri, string expected)
106106
}
107107

108108
/// <summary>
109-
/// Tests the selector property of the modal page control.
109+
/// Tests the selector property of the remote modal page control.
110110
/// </summary>
111111
[Theory]
112112
[InlineData(null, @"<div class=""wx-webui-modal-page"" *>*</div>")]

src/WebExpress.WebUI.Test/WebControl/UnitTestControlPanelOverflow.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@
55
namespace WebExpress.WebUI.Test.WebControl
66
{
77
/// <summary>
8-
/// Tests the toast control.
8+
/// Tests the overflow panel control.
99
/// </summary>
1010
[Collection("NonParallelTests")]
1111
public class UnitTestControlPanelOverflow
1212
{
1313
/// <summary>
14-
/// Tests the id property of the toast control.
14+
/// Tests the id property of the overflow panel control.
1515
/// </summary>
1616
[Theory]
1717
[InlineData(null, @"<div class=""wx-webui-overflow""></div>")]
@@ -33,7 +33,7 @@ public void Id(string id, string expected)
3333
}
3434

3535
/// <summary>
36-
/// Tests the background color property of the toast control.
36+
/// Tests the background color property of the overflow panel control.
3737
/// </summary>
3838
[Theory]
3939
[InlineData(TypeColorBackground.Default, @"<div class=""wx-webui-overflow""></div>")]
@@ -63,7 +63,7 @@ public void BackgroundColor(TypeColorBackground backgroundColor, string expected
6363
}
6464

6565
/// <summary>
66-
/// Tests the theme property of the panel control.
66+
/// Tests the theme property of the overflow panel control.
6767
/// </summary>
6868
[Theory]
6969
[InlineData(TypeTheme.None, @"<div class=""wx-webui-overflow""></div>")]
@@ -87,7 +87,7 @@ public void Theme(TypeTheme theme, string expected)
8787
}
8888

8989
/// <summary>
90-
/// Tests the add function of the toast control.
90+
/// Tests the add function of the overflow panel control.
9191
/// </summary>
9292
[Theory]
9393
[InlineData(typeof(ControlText), @"<div class=""wx-webui-overflow""><div></div></div>")]

src/WebExpress.WebUI.Test/WebControl/UnitTestControlResponsive.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
namespace WebExpress.WebUI.Test.WebControl
66
{
77
/// <summary>
8-
/// Tests the pagination control.
8+
/// Tests the responsive control.
99
/// </summary>
1010
[Collection("NonParallelTests")]
1111
public class UnitTestControlResponsive

src/WebExpress.WebUI.Test/WebControl/UnitTestControlSidebarItemControl.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ public void Color(TypeColorText color, string expected)
115115
}
116116

117117
/// <summary>
118-
/// Tests the mode property of the sidebar item divider control.
118+
/// Tests the mode property of the sidebar item control.
119119
/// </summary>
120120
[Theory]
121121
[InlineData(TypeSidebarModeExtended.Default, @"<div class=""wx-sidebar-control""></div>")]
@@ -140,7 +140,7 @@ public void Mode(TypeSidebarModeExtended mode, string expected)
140140
}
141141

142142
/// <summary>
143-
/// Tests the content property of the sidebar item divider control.
143+
/// Tests the content property of the sidebar item control.
144144
/// </summary>
145145
[Fact]
146146
public void Control()

src/WebExpress.WebUI.Test/WebControl/UnitTestControlSidebarItemDynamic.cs

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -138,34 +138,5 @@ public void Mode(TypeSidebarModeExtended mode, string expected)
138138
// validation
139139
AssertExtensions.EqualWithPlaceholders(expected, html);
140140
}
141-
142-
/// <summary>
143-
/// Tests the render content function of the sidebar item control.
144-
/// </summary>
145-
[Fact]
146-
public void RenderControl()
147-
{
148-
// preconditions
149-
var componentHub = UnitTestControlFixture.CreateAndRegisterComponentHubMock();
150-
var context = UnitTestControlFixture.CreateRenderContextMock();
151-
var visualTree = new VisualTreeControl(componentHub, context.PageContext);
152-
var control = new ControlSidebarItemControl()
153-
{
154-
Content = new ControlText()
155-
{
156-
Text = "Content"
157-
},
158-
};
159-
160-
// test execution
161-
var html = control.Render(context, visualTree);
162-
163-
// validation
164-
AssertExtensions.EqualWithPlaceholders
165-
(
166-
@"<div class=""wx-sidebar-control""><div>Content</div></div>",
167-
html
168-
);
169-
}
170141
}
171142
}

src/WebExpress.WebUI/WebControl/ControlCarouselItem.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public class ControlCarouselItem
1616
public string Text { get; set; }
1717

1818
/// <summary>
19-
/// Retruns or sets the slideshow element, such as an image.
19+
/// Returns or sets the slideshow element, such as an image.
2020
/// </summary>
2121
public IControl Control { get; set; }
2222

src/WebExpress.WebUI/WebControl/ControlHtml.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ namespace WebExpress.WebUI.WebControl
99
public class ControlHtml : Control
1010
{
1111
/// <summary>
12-
/// Retruns or sets the html source code.
12+
/// Returns or sets the html source code.
1313
/// </summary>
1414
public string Html { get; set; }
1515

0 commit comments

Comments
 (0)