Skip to content

Commit 481d93e

Browse files
IsFalse
1 parent d74b62f commit 481d93e

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

src/RapidCMS.Core.Tests/Forms/EditContextCustomValidationConfigurationTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public async Task WhenInvalidEntityIsValidated_ThenIsValidShouldReturnFalseAsync
4141

4242
// assert
4343
Assert.That(await _subject.IsValidAsync(), Is.False);
44-
Assert.IsFalse(await _subject.IsValidAsync());
44+
Assert.That(await _subject.IsValidAsync(), Is.False);
4545
Assert.AreEqual("Id is null", _subject.GetPropertyState("Id").GetValidationMessages().First());
4646
}
4747

src/RapidCMS.Core.Tests/Forms/EditContextCustomValidationTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public async Task WhenInvalidEntityIsValidated_ThenIsValidShouldReturnFalseAsync
4040
_subject.NotifyPropertyIncludedInForm(PropertyMetadataHelper.GetPropertyMetadata<Entity, string>(x => x.Id));
4141

4242
// assert
43-
Assert.IsFalse(await _subject.IsValidAsync());
43+
Assert.That(await _subject.IsValidAsync(), Is.False);
4444
Assert.AreEqual("Id is null", _subject.GetPropertyState("Id").GetValidationMessages().First());
4545
}
4646

src/RapidCMS.Core.Tests/Forms/EditContextCustomValidationVariantsTests.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ public async Task WhenInvalidEntityIsValidated_ThenIsValidShouldReturnFalseAsync
4444
_subject.NotifyPropertyIncludedInForm(PropertyMetadataHelper.GetPropertyMetadata<Entity, string>(x => x.Id));
4545

4646
// assert
47-
Assert.IsFalse(await _subject.IsValidAsync());
47+
Assert.That(await _subject.IsValidAsync(), Is.False);
4848
Assert.AreEqual("Id is null", _subject.GetPropertyState("Id").GetValidationMessages().First());
4949
}
5050

@@ -73,7 +73,7 @@ public async Task WhenInvalidEntityVariantAIsValidated_ThenIsValidShouldReturnFa
7373
_subject.NotifyPropertyIncludedInForm(PropertyMetadataHelper.GetPropertyMetadata<Entity, string>(x => x.Id));
7474

7575
// assert
76-
Assert.IsFalse(await _subject.IsValidAsync());
76+
Assert.That(await _subject.IsValidAsync(), Is.False);
7777
Assert.AreEqual("Id of A-variant cannot be A", _subject.GetPropertyState("Id").GetValidationMessages().First());
7878
}
7979

@@ -102,7 +102,7 @@ public async Task WhenInvalidEntityVariantBIsValidated_ThenIsValidShouldReturnFa
102102
_subject.NotifyPropertyIncludedInForm(PropertyMetadataHelper.GetPropertyMetadata<Entity, string>(x => x.Id));
103103

104104
// assert
105-
Assert.IsFalse(await _subject.IsValidAsync());
105+
Assert.That(await _subject.IsValidAsync(), Is.False);
106106
Assert.AreEqual("Id of B-variant cannot be B", _subject.GetPropertyState("Id").GetValidationMessages().First());
107107
}
108108

src/RapidCMS.Core.Tests/Forms/EditContextTests.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ public async Task WhenEntityIsInvalidButTouched_ThenEditContextIsInvalidAsync()
115115
_subject.NotifyPropertyIncludedInForm(_property);
116116

117117
// act & assert
118-
Assert.IsFalse(await _subject.IsValidAsync());
118+
Assert.That(await _subject.IsValidAsync(), Is.False);
119119
}
120120

121121
[Test]
@@ -173,7 +173,7 @@ public async Task WhenPropertyIsInvalidButTouched_ThenEditContextIsInvalidAsync(
173173
await _subject.NotifyPropertyChangedAsync(_property);
174174

175175
// act & assert
176-
Assert.IsFalse(_subject.IsValid(_property));
176+
Assert.That(_subject.IsValid(_property), Is.False);
177177
}
178178

179179
[Test]
@@ -199,7 +199,7 @@ public void WhenPropertyIsValidAndTouched_ThenEditContextIsValid()
199199
public void WhenEntityIsNotTouched_ThenEditContextIsNotModified()
200200
{
201201
// act & assert
202-
Assert.IsFalse(_subject.IsModified());
202+
Assert.That(_subject.IsModified(), Is.False);
203203
}
204204

205205
[Test]
@@ -216,7 +216,7 @@ public async Task WhenEntityIsTouched_ThenEditContextIsModifiedAsync()
216216
public void WhenPropertyIsNotTouched_ThenPropertyIsNotValidated()
217217
{
218218
// act & assert
219-
Assert.IsFalse(_subject.WasValidated(_property));
219+
Assert.That(_subject.WasValidated(_property), Is.False);
220220
}
221221

222222
[Test]
@@ -237,7 +237,7 @@ public void WhenValidationMessageIsAddedToProperty_ThenPropertyIsInvalid()
237237

238238
// assert
239239
Assert.IsTrue(_subject.WasValidated(_property));
240-
Assert.IsFalse(_subject.IsValid(_property));
240+
Assert.That(_subject.IsValid(_property), Is.False);
241241
}
242242

243243
[Test]
@@ -258,7 +258,7 @@ public async Task WhenNestedPropertyIsTouched_ThenPropertyIsValidatedAsync()
258258

259259
// assert
260260
Assert.IsTrue(_subject.WasValidated(_nestedProperty));
261-
Assert.IsFalse(_subject.IsValid(_nestedProperty));
261+
Assert.That(_subject.IsValid(_nestedProperty), Is.False);
262262
}
263263

264264
[Test]
@@ -287,7 +287,7 @@ public async Task WhenNestedPropertyIsTouchedAndValid_ThenPropertyIsValidatedAnd
287287
public void WhenNestedPropertyIsNotTouched_ThenPropertyIsNotValidated()
288288
{
289289
// assert
290-
Assert.IsFalse(_subject.WasValidated(_nestedProperty));
290+
Assert.That(_subject.WasValidated(_nestedProperty), Is.False);
291291
Assert.IsTrue(_subject.IsValid(_nestedProperty));
292292
}
293293

0 commit comments

Comments
 (0)