Skip to content

Commit

Permalink
Add hidden overloads for binary compatibility for ConfigReader and fr…
Browse files Browse the repository at this point in the history
…iends
  • Loading branch information
bradwilson committed Mar 15, 2024
1 parent c10b7a2 commit 4b2b9fa
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/xunit.runner.utility/Configuration/ConfigReader.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System.Collections.Generic;
using System.ComponentModel;
using System.Globalization;
using System.IO;

Expand All @@ -9,6 +10,11 @@ namespace Xunit
/// </summary>
public static class ConfigReader
{
/// <summary/>
[EditorBrowsable(EditorBrowsableState.Never)]
public static TestAssemblyConfiguration Load(string assemblyFileName, string configFileName = null) =>
Load(assemblyFileName, configFileName, null);

/// <summary>
/// Loads the test assembly configuration for the given test assembly.
/// </summary>
Expand All @@ -34,6 +40,11 @@ public static TestAssemblyConfiguration Load(string assemblyFileName, string con
return new TestAssemblyConfiguration();
}

/// <summary/>
[EditorBrowsable(EditorBrowsableState.Never)]
public static TestAssemblyConfiguration Load(Stream configStream) =>
Load(configStream, null);

/// <summary>
/// Loads the test assembly configuration for the given test assembly from a JSON stream. Caller is responsible for opening the stream.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Configuration;
using System.Globalization;
using System.IO;
Expand All @@ -13,6 +14,11 @@ namespace Xunit
/// </summary>
public static class ConfigReader_Configuration
{
/// <summary/>
[EditorBrowsable(EditorBrowsableState.Never)]
public static TestAssemblyConfiguration Load(string assemblyFileName, string configFileName = null) =>
Load(assemblyFileName, configFileName, null);

/// <summary>
/// Loads the test assembly configuration for the given test assembly.
/// </summary>
Expand Down
11 changes: 11 additions & 0 deletions src/xunit.runner.utility/Configuration/ConfigReader_Json.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Globalization;
using System.IO;

Expand All @@ -14,6 +15,11 @@ namespace Xunit
/// </summary>
public static class ConfigReader_Json
{
/// <summary/>
[EditorBrowsable(EditorBrowsableState.Never)]
public static TestAssemblyConfiguration Load(Stream configStream) =>
Load(configStream, null);

/// <summary>
/// Loads the test assembly configuration for the given test assembly from a JSON stream. Caller is responsible for opening the stream.
/// </summary>
Expand All @@ -23,6 +29,11 @@ public static class ConfigReader_Json
public static TestAssemblyConfiguration Load(Stream configStream, List<string> warnings = null) =>
LoadConfiguration(configStream, null, warnings);

/// <summary/>
[EditorBrowsable(EditorBrowsableState.Never)]
public static TestAssemblyConfiguration Load(string assemblyFileName, string configFileName = null) =>
Load(assemblyFileName, configFileName, null);

/// <summary>
/// Loads the test assembly configuration for the given test assembly.
/// </summary>
Expand Down

0 comments on commit 4b2b9fa

Please sign in to comment.