Removes CheckAbsoulte and updates unit tests to match

This commit is contained in:
Tig Kindel
2024-01-05 12:01:59 -07:00
parent c6570a5bfd
commit 42eb0c36cb
6 changed files with 1693 additions and 1659 deletions

View File

@@ -39,6 +39,9 @@ resharper_csharp_stick_comment = false
resharper_csharp_wrap_parameters_style = chop_if_long
resharper_force_attribute_style = separate
resharper_indent_type_constraints = true
resharper_xmldoc_indent_size = 2
resharper_xmldoc_indent_style = space
resharper_xmldoc_tab_width = 2
#resharper_int_align_binary_expressions = true
resharper_int_align_comments = true
resharper_int_align_invocations = true
@@ -96,15 +99,7 @@ csharp_style_var_for_built_in_types = true:none
resharper_wrap_before_linq_expression = true
resharper_wrap_chained_binary_expressions = chop_if_long
resharper_wrap_chained_binary_patterns = chop_if_long
resharper_xmldoc_indent_size = 2
resharper_xmldoc_indent_style = space
resharper_xmldoc_indent_text = DoNotTouch
resharper_xmldoc_linebreaks_inside_tags_for_elements_longer_than = 120
resharper_xmldoc_max_blank_lines_between_tags = 1
resharper_xmldoc_max_line_length = 100
resharper_xmldoc_space_before_self_closing = false
resharper_xmldoc_tab_width = 2
resharper_xmldoc_use_indent_from_vs = true
[*.{cs,vb}]
dotnet_style_operator_placement_when_wrapping = beginning_of_line

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -139,9 +139,9 @@ public class LayoutTests {
Assert.True (v.IsInitialized);
v.Width = Dim.Fill (1);
Assert.Throws<ArgumentException> (() => v.Width = 75);
v.LayoutStyle = LayoutStyle.Absolute;
v.LayoutStyle = LayoutStyle.Computed;
v.Width = 75;
v.LayoutStyle = LayoutStyle.Absolute;
Assert.True (v.TrySetWidth (60, out rWidth));
Assert.Equal (60, rWidth);
}
@@ -179,7 +179,8 @@ public class LayoutTests {
Assert.True (v.IsInitialized);
v.Height = Dim.Fill (1);
Assert.Throws<ArgumentException> (() => v.Height = 15);
v.LayoutStyle = LayoutStyle.Computed;
v.Height = 15;
v.LayoutStyle = LayoutStyle.Absolute;
v.Height = 15;
Assert.True (v.TrySetHeight (5, out rHeight));

View File

@@ -671,39 +671,6 @@ public class PosTests {
Assert.Throws<ArgumentException> (() => pos = Pos.Percent (1000001));
}
[Fact]
public void ForceValidatePosDim_True_Pos_Validation_Throws_If_NewValue_Is_PosAbsolute_And_OldValue_Is_Another_Type ()
{
Application.Init (new FakeDriver ());
var t = Application.Top;
var w = new Window () {
X = Pos.Left (t) + 2,
Y = Pos.At (2)
};
var v = new View () {
X = Pos.Center (),
Y = Pos.Percent (10),
ValidatePosDim = true
};
w.Add (v);
t.Add (w);
t.Ready += (s, e) => {
Assert.Equal (2, w.X = 2);
Assert.Equal (2, w.Y = 2);
Assert.Throws<ArgumentException> (() => v.X = 2);
Assert.Throws<ArgumentException> (() => v.Y = 2);
};
Application.Iteration += (s, a) => Application.RequestStop ();
Application.Run ();
Application.Shutdown ();
}
[Fact]
public void Pos_Validation_Do_Not_Throws_If_NewValue_Is_PosAbsolute_And_OldValue_Is_Null ()
{