Skip to content

Commit

Permalink
Fix codestyle issue IDE0052
Browse files Browse the repository at this point in the history
  • Loading branch information
ITaluone committed Apr 7, 2022
1 parent 8d9a383 commit f5f65ea
Showing 1 changed file with 19 additions and 18 deletions.
37 changes: 19 additions & 18 deletions Tests/Benchmarks/UsersOfGetClosedGenericInterfaces.cs
Expand Up @@ -24,14 +24,13 @@ public class UsersOfGetClosedGenericInterfaces
private GenericEnumerableEquivalencyStep enumerableStep;

private IEquivalencyValidationContext context;
private IEquivalencyAssertionOptions config;

private class Context : IEquivalencyValidationContext
{
public INode CurrentNode { get; }
public Reason Reason { get; }
public Tracer Tracer { get; }
public IEquivalencyAssertionOptions Options { get; }
public IEquivalencyAssertionOptions Options { get; internal set; }
public bool IsCyclicReference(object expectation) => throw new NotImplementedException();

public IEquivalencyValidationContext AsNestedMember(IMember expectationMember) => throw new NotImplementedException();
Expand Down Expand Up @@ -148,25 +147,27 @@ public void GlobalSetup()
break;

default:
{
if (DataType == typeof(TimeSpan))
values[i] = faker.Date.Future() - faker.Date.Future();
else if (DataType == typeof(Guid))
values[i] = faker.Random.Guid();
else if (DataType == typeof(Dictionary<int, int>))
values[i] = new Dictionary<int, int>() { { faker.Random.Int(), faker.Random.Int() } };
else if (DataType == typeof(IEnumerable<int>))
values[i] = new int[] { faker.Random.Int(), faker.Random.Int() };
else
throw new Exception("Unable to populate data of type " + DataType);

break;
}
{
if (DataType == typeof(TimeSpan))
values[i] = faker.Date.Future() - faker.Date.Future();
else if (DataType == typeof(Guid))
values[i] = faker.Random.Guid();
else if (DataType == typeof(Dictionary<int, int>))
values[i] = new Dictionary<int, int>() { { faker.Random.Int(), faker.Random.Int() } };
else if (DataType == typeof(IEnumerable<int>))
values[i] = new int[] { faker.Random.Int(), faker.Random.Int() };
else
throw new Exception("Unable to populate data of type " + DataType);

break;
}
}
}

context = new Context();
config = new Config();
context = new Context()
{
Options = new Config()
};
}

[Benchmark]
Expand Down

0 comments on commit f5f65ea

Please sign in to comment.