Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions test/xUnit/csharp/test_CommandLineParser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -969,7 +969,7 @@ public static void TestParameter_SettingsFile_Not_Exists(params string[] command

public class TestDataSettingsFile : IEnumerable<object[]>
{
private string _fileName = Path.GetTempFileName();
private readonly string _fileName = Path.GetTempFileName();

public IEnumerator<object[]> GetEnumerator()
{
Expand Down Expand Up @@ -1162,7 +1162,7 @@ public static void TestParameter_WorkingDirectory_RemoveTrailingCharacter(params

public class TestDataLastFile : IEnumerable<object[]>
{
private string _fileName = Path.GetTempFileName();
private readonly string _fileName = Path.GetTempFileName();

public IEnumerator<object[]> GetEnumerator()
{
Expand Down
4 changes: 2 additions & 2 deletions test/xUnit/csharp/test_FileSystemProvider.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ namespace PSTests.Parallel
{
public class FileSystemProviderTests : IDisposable
{
private string testPath;
private string testContent;
private readonly string testPath;
private readonly string testContent;

public FileSystemProviderTests()
{
Expand Down
2 changes: 1 addition & 1 deletion test/xUnit/csharp/test_PSConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ internal void ForceReadingFromFile()

public class PowerShellPolicyTests : IClassFixture<PowerShellPolicyFixture>
{
private PowerShellPolicyFixture fixture;
private readonly PowerShellPolicyFixture fixture;

public PowerShellPolicyTests(PowerShellPolicyFixture fixture)
{
Expand Down
4 changes: 2 additions & 2 deletions test/xUnit/csharp/test_Runspace.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ namespace PSTests.Sequential
// otherwise Invoke will not return any objects
public class RunspaceTests
{
private static int count = 1;
private static string script = string.Format($"get-command get-command");
private static readonly int count = 1;
private static readonly string script = string.Format($"get-command get-command");

[Fact]
public void TestRunspaceWithPipeline()
Expand Down