Skip to content

Commit 632346c

Browse files
committed
Upgrade NUnit 3.6.1 to 3.8.1
1 parent db4da83 commit 632346c

8 files changed

Lines changed: 24 additions & 24 deletions

TestHelpers.Tests/MockDirectoryInfoTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ public void MockDirectoryInfo_Constructor_ShouldThrowArgumentNullException_IfArg
235235

236236
// Assert
237237
var exception = Assert.Throws<ArgumentNullException>(action);
238-
Assert.That(exception.Message, Is.StringStarting("Value cannot be null."));
238+
Assert.That(exception.Message, Does.StartWith("Value cannot be null."));
239239
}
240240

241241
[Test]
@@ -262,7 +262,7 @@ public void MockDirectoryInfo_Constructor_ShouldThrowArgumentException_IfArgumen
262262

263263
// Assert
264264
var exception = Assert.Throws<ArgumentException>(action);
265-
Assert.That(exception.Message, Is.StringStarting("The path is not of a legal form."));
265+
Assert.That(exception.Message, Does.StartWith("The path is not of a legal form."));
266266
}
267267

268268
[Test]

TestHelpers.Tests/MockFileCopyTests.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ public void MockFile_Copy_ShouldThrowArgumentNullExceptionWhenSourceIsNull_Messa
8383

8484
var exception = Assert.Throws<ArgumentNullException>(() => fileSystem.File.Copy(null, destFilePath));
8585

86-
Assert.That(exception.Message, Is.StringStarting("File name cannot be null."));
86+
Assert.That(exception.Message, Does.StartWith("File name cannot be null."));
8787
}
8888

8989
[Test]
@@ -201,7 +201,7 @@ public void MockFile_Copy_ShouldThrowArgumentExceptionWhenSourceIsEmpty_Message(
201201

202202
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Copy(string.Empty, destFilePath));
203203

204-
Assert.That(exception.Message, Is.StringStarting("Empty file name is not legal."));
204+
Assert.That(exception.Message, Does.StartWith("Empty file name is not legal."));
205205
}
206206

207207
[Test]
@@ -224,7 +224,7 @@ public void MockFile_Copy_ShouldThrowArgumentExceptionWhenSourceIsStringOfBlanks
224224

225225
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Copy(sourceFilePath, destFilePath));
226226

227-
Assert.That(exception.Message, Is.StringStarting("The path is not of a legal form."));
227+
Assert.That(exception.Message, Does.StartWith("The path is not of a legal form."));
228228
}
229229

230230
[Test]
@@ -235,7 +235,7 @@ public void MockFile_Copy_ShouldThrowArgumentNullExceptionWhenTargetIsNull_Messa
235235

236236
var exception = Assert.Throws<ArgumentNullException>(() => fileSystem.File.Copy(sourceFilePath, null));
237237

238-
Assert.That(exception.Message, Is.StringStarting("File name cannot be null."));
238+
Assert.That(exception.Message, Does.StartWith("File name cannot be null."));
239239
}
240240

241241
[Test]
@@ -258,7 +258,7 @@ public void MockFile_Copy_ShouldThrowArgumentExceptionWhenTargetIsStringOfBlanks
258258

259259
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Copy(sourceFilePath, destFilePath));
260260

261-
Assert.That(exception.Message, Is.StringStarting("The path is not of a legal form."));
261+
Assert.That(exception.Message, Does.StartWith("The path is not of a legal form."));
262262
}
263263

264264
[Test]
@@ -269,7 +269,7 @@ public void MockFile_Copy_ShouldThrowArgumentExceptionWhenTargetIsEmpty_Message(
269269

270270
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Copy(sourceFilePath, string.Empty));
271271

272-
Assert.That(exception.Message, Is.StringStarting("Empty file name is not legal."));
272+
Assert.That(exception.Message, Does.StartWith("Empty file name is not legal."));
273273
}
274274
}
275275
}

TestHelpers.Tests/MockFileCreateTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ public void MockFile_Create_ShouldThrowArgumentNullExceptionIfPathIsNull()
144144

145145
// Assert
146146
var exception = Assert.Throws<ArgumentNullException>(action);
147-
Assert.That(exception.Message, Is.StringStarting("Path cannot be null."));
147+
Assert.That(exception.Message, Does.StartWith("Path cannot be null."));
148148
}
149149
}
150150
}

TestHelpers.Tests/MockFileMoveTests.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public void MockFile_Move_ShouldThrowArgumentNullExceptionWhenSourceIsNull_Messa
5454

5555
var exception = Assert.Throws<ArgumentNullException>(() => fileSystem.File.Move(null, destFilePath));
5656

57-
Assert.That(exception.Message, Is.StringStarting("File name cannot be null."));
57+
Assert.That(exception.Message, Does.StartWith("File name cannot be null."));
5858
}
5959

6060
[Test]
@@ -171,7 +171,7 @@ public void MockFile_Move_ShouldThrowArgumentExceptionWhenSourceIsEmpty_Message(
171171

172172
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Move(string.Empty, destFilePath));
173173

174-
Assert.That(exception.Message, Is.StringStarting("Empty file name is not legal."));
174+
Assert.That(exception.Message, Does.StartWith("Empty file name is not legal."));
175175
}
176176

177177
[Test]
@@ -193,7 +193,7 @@ public void MockFile_Move_ShouldThrowArgumentExceptionWhenSourceIsStringOfBlanks
193193

194194
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Move(sourceFilePath, destFilePath));
195195

196-
Assert.That(exception.Message, Is.StringStarting("The path is not of a legal form."));
196+
Assert.That(exception.Message, Does.StartWith("The path is not of a legal form."));
197197
}
198198

199199
[Test]
@@ -204,7 +204,7 @@ public void MockFile_Move_ShouldThrowArgumentNullExceptionWhenTargetIsNull_Messa
204204

205205
var exception = Assert.Throws<ArgumentNullException>(() => fileSystem.File.Move(sourceFilePath, null));
206206

207-
Assert.That(exception.Message, Is.StringStarting("File name cannot be null."));
207+
Assert.That(exception.Message, Does.StartWith("File name cannot be null."));
208208
}
209209

210210
[Test]
@@ -226,7 +226,7 @@ public void MockFile_Move_ShouldThrowArgumentExceptionWhenTargetIsStringOfBlanks
226226

227227
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Move(sourceFilePath, destFilePath));
228228

229-
Assert.That(exception.Message, Is.StringStarting("The path is not of a legal form."));
229+
Assert.That(exception.Message, Does.StartWith("The path is not of a legal form."));
230230
}
231231

232232
[Test]
@@ -237,7 +237,7 @@ public void MockFile_Move_ShouldThrowArgumentExceptionWhenTargetIsEmpty_Message(
237237

238238
var exception = Assert.Throws<ArgumentException>(() => fileSystem.File.Move(sourceFilePath, string.Empty));
239239

240-
Assert.That(exception.Message, Is.StringStarting("Empty file name is not legal."));
240+
Assert.That(exception.Message, Does.StartWith("Empty file name is not legal."));
241241
}
242242

243243
[Test]

TestHelpers.Tests/MockFileTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -267,7 +267,7 @@ public void MockFile_GetAttributeWithEmptyParameter_ShouldThrowOneArgumentExcept
267267

268268
// Assert
269269
var exception = Assert.Throws<ArgumentException>(action);
270-
Assert.That(exception.Message, Is.StringStarting("The path is not of a legal form."));
270+
Assert.That(exception.Message, Does.StartWith("The path is not of a legal form."));
271271
}
272272

273273
[Test]

TestHelpers.Tests/MockFileWriteAllBytesTests.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ public void MockFile_WriteAllBytes_ShouldThrowAnArgumentNullExceptionIfContainsI
8282

8383
// Assert
8484
var exception = Assert.Throws<ArgumentNullException>(action);
85-
Assert.That(exception.Message, Is.StringStarting("Path cannot be null."));
85+
Assert.That(exception.Message, Does.StartWith("Path cannot be null."));
8686
Assert.That(exception.ParamName, Is.EqualTo("path"));
8787
}
8888

@@ -98,7 +98,7 @@ public void MockFile_WriteAllBytes_ShouldThrowAnArgumentNullExceptionIfBytesAreN
9898

9999
// Assert
100100
var exception = Assert.Throws<ArgumentNullException>(action);
101-
Assert.That(exception.Message, Is.StringStarting("Value cannot be null."));
101+
Assert.That(exception.Message, Does.StartWith("Value cannot be null."));
102102
Assert.That(exception.ParamName, Is.EqualTo("bytes"));
103103
}
104104
}

TestHelpers.Tests/MockFileWriteAllLinesTests.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -221,8 +221,8 @@ public void MockFile_WriteAllLinesGeneric_ShouldThrowAnArgumentNullExceptionIfPa
221221

222222
// Assert
223223
var exception = Assert.Throws<ArgumentNullException>(action);
224-
Assert.That(exception.Message, Is.StringStarting("Value cannot be null."));
225-
Assert.That(exception.ParamName, Is.StringStarting("path"));
224+
Assert.That(exception.Message, Does.StartWith("Value cannot be null."));
225+
Assert.That(exception.ParamName, Does.StartWith("path"));
226226
}
227227

228228
[TestCaseSource(typeof(TestDataForWriteAllLines), "ForNullEncoding")]
@@ -236,8 +236,8 @@ public void MockFile_WriteAllLinesGeneric_ShouldThrowAnArgumentNullExceptionIfEn
236236

237237
// Assert
238238
var exception = Assert.Throws<ArgumentNullException>(action);
239-
Assert.That(exception.Message, Is.StringStarting("Value cannot be null."));
240-
Assert.That(exception.ParamName, Is.StringStarting("encoding"));
239+
Assert.That(exception.Message, Does.StartWith("Value cannot be null."));
240+
Assert.That(exception.ParamName, Does.StartWith("encoding"));
241241
}
242242

243243
[TestCaseSource(typeof(TestDataForWriteAllLines), "ForIllegalPath")]
@@ -295,7 +295,7 @@ public void MockFile_WriteAllLinesGeneric_ShouldThrowAnArgumentNullExceptionIfCo
295295

296296
// Assert
297297
var exception = Assert.Throws<ArgumentNullException>(action);
298-
Assert.That(exception.Message, Is.StringStarting("Value cannot be null."));
298+
Assert.That(exception.Message, Does.StartWith("Value cannot be null."));
299299
Assert.That(exception.ParamName, Is.EqualTo("contents"));
300300
}
301301
}

TestHelpers.Tests/TestHelpers.Tests.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
</ItemGroup>
3030

3131
<ItemGroup>
32-
<PackageReference Include="nunit" Version="3.6.1" />
32+
<PackageReference Include="nunit" Version="3.8.1" />
3333
</ItemGroup>
3434

3535
<ItemGroup>

0 commit comments

Comments
 (0)