align files to .editorconfig (#203)

* align files to .editorconfig

* fix space cause build failed
This commit is contained in:
Boshi Lian
2018-09-27 10:50:39 -07:00
committed by Brendan Burns
parent 09a8c8773a
commit 9372e3291f
51 changed files with 4610 additions and 4611 deletions

View File

@@ -1,4 +1,4 @@
using System; using System;
namespace Fractions.Extensions { namespace Fractions.Extensions {
internal static class MathExt { internal static class MathExt {

View File

@@ -1,4 +1,4 @@
using System; using System;
namespace Fractions.Formatter { namespace Fractions.Formatter {
/// <summary> /// <summary>

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Globalization; using System.Globalization;
using System.Numerics; using System.Numerics;
using System.Text; using System.Text;
@@ -82,7 +82,7 @@ namespace Fractions.Formatter {
} }
private static string FormatGeneral(Fraction fraction) { private static string FormatGeneral(Fraction fraction) {
if (fraction.Denominator == BigInteger.One) { if (fraction.Denominator == BigInteger.One) {
return fraction.Numerator.ToString(CultureInfo.InvariantCulture); return fraction.Numerator.ToString(CultureInfo.InvariantCulture);
} }

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Numerics; using System.Numerics;
namespace Fractions { namespace Fractions {

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Numerics; using System.Numerics;
namespace Fractions { namespace Fractions {

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Globalization; using System.Globalization;
using System.Numerics; using System.Numerics;
using Fractions.Extensions; using Fractions.Extensions;
@@ -246,7 +246,7 @@ namespace Fractions {
var breakCounter = 0; var breakCounter = 0;
while (MathExt.RemainingDigitsAfterTheDecimalPoint(remainingDigits) while (MathExt.RemainingDigitsAfterTheDecimalPoint(remainingDigits)
&& Math.Abs(absoluteValue - (double) numerator / denominator) > double.Epsilon) { && Math.Abs(absoluteValue - (double) numerator / denominator) > double.Epsilon) {
remainingDigits = 1.0 / (remainingDigits - Math.Floor(remainingDigits)); remainingDigits = 1.0 / (remainingDigits - Math.Floor(remainingDigits));

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Numerics; using System.Numerics;
namespace Fractions { namespace Fractions {

View File

@@ -1,4 +1,4 @@

namespace Fractions { namespace Fractions {
public partial struct Fraction public partial struct Fraction
{ {

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Numerics; using System.Numerics;
namespace Fractions { namespace Fractions {

View File

@@ -1,4 +1,4 @@
using System.Numerics; using System.Numerics;
namespace Fractions { namespace Fractions {
public partial struct Fraction { public partial struct Fraction {

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Globalization; using System.Globalization;
using Fractions.Formatter; using Fractions.Formatter;

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.ComponentModel; using System.ComponentModel;
using System.Numerics; using System.Numerics;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
@@ -39,14 +39,14 @@ namespace Fractions {
/// </summary> /// </summary>
public bool IsPositive => _numerator.Sign == 1 && _denominator.Sign == 1 || public bool IsPositive => _numerator.Sign == 1 && _denominator.Sign == 1 ||
_numerator.Sign == -1 && _denominator.Sign == -1; _numerator.Sign == -1 && _denominator.Sign == -1;
/// <summary> /// <summary>
/// <c>true</c> if the value is negative (lesser than 0). /// <c>true</c> if the value is negative (lesser than 0).
/// </summary> /// </summary>
public bool IsNegative => _numerator.Sign == -1 && _denominator.Sign == 1 || public bool IsNegative => _numerator.Sign == -1 && _denominator.Sign == 1 ||
_numerator.Sign == 1 && _denominator.Sign == -1; _numerator.Sign == 1 && _denominator.Sign == -1;
/// <summary> /// <summary>
/// <c>true</c> if the fraction has a real (calculated) value of 0. /// <c>true</c> if the fraction has a real (calculated) value of 0.

View File

@@ -1,4 +1,4 @@
namespace Fractions { namespace Fractions {
/// <summary> /// <summary>
/// The fraction's state. /// The fraction's state.
/// </summary> /// </summary>

View File

@@ -1,4 +1,4 @@
using System; using System;
namespace Fractions { namespace Fractions {
/// <summary> /// <summary>

View File

@@ -1,4 +1,4 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.ComponentModel; using System.ComponentModel;
using System.Globalization; using System.Globalization;

View File

@@ -216,9 +216,9 @@ namespace k8s
#endif #endif
if ((!string.IsNullOrWhiteSpace(config.ClientCertificateData) || if ((!string.IsNullOrWhiteSpace(config.ClientCertificateData) ||
!string.IsNullOrWhiteSpace(config.ClientCertificateFilePath)) && !string.IsNullOrWhiteSpace(config.ClientCertificateFilePath)) &&
(!string.IsNullOrWhiteSpace(config.ClientCertificateKeyData) || (!string.IsNullOrWhiteSpace(config.ClientCertificateKeyData) ||
!string.IsNullOrWhiteSpace(config.ClientKeyFilePath))) !string.IsNullOrWhiteSpace(config.ClientKeyFilePath)))
{ {
var cert = CertUtils.GeneratePfx(config); var cert = CertUtils.GeneratePfx(config);

View File

@@ -215,7 +215,7 @@ namespace k8s
userCredentialsFound = true; userCredentialsFound = true;
} }
else if (!string.IsNullOrWhiteSpace(userDetails.UserCredentials.UserName) && else if (!string.IsNullOrWhiteSpace(userDetails.UserCredentials.UserName) &&
!string.IsNullOrWhiteSpace(userDetails.UserCredentials.Password)) !string.IsNullOrWhiteSpace(userDetails.UserCredentials.Password))
{ {
Username = userDetails.UserCredentials.UserName; Username = userDetails.UserCredentials.UserName;
Password = userDetails.UserCredentials.Password; Password = userDetails.UserCredentials.Password;

View File

@@ -1,4 +1,3 @@
using Xunit; using Xunit;
[assembly: CollectionBehavior(DisableTestParallelization = true)] [assembly: CollectionBehavior(DisableTestParallelization = true)]

View File

@@ -475,7 +475,7 @@ namespace k8s.Tests
await Task.WhenAny(eventsReceived.WaitAsync(), Task.Delay(TestTimeout)); await Task.WhenAny(eventsReceived.WaitAsync(), Task.Delay(TestTimeout));
Assert.True( Assert.True(
eventsReceived.CurrentCount == 0, eventsReceived.CurrentCount == 0,
"Timed out waiting for all events / errors to be received." "Timed out waiting for all events / errors to be received."
); );
@@ -584,21 +584,21 @@ namespace k8s.Tests
Spec = new V1PodSpec() Spec = new V1PodSpec()
{ {
Containers = new List<V1Container>() Containers = new List<V1Container>()
{ {
new V1Container() new V1Container()
{ {
Image = "ubuntu/xenial", Image = "ubuntu/xenial",
Name = "runner", Name = "runner",
Command = new List<string>() Command = new List<string>()
{ {
"/bin/bash", "/bin/bash",
"-c", "-c",
"--" "--"
}, },
Args = new List<string>() Args = new List<string>()
{ {
"trap : TERM INT; sleep infinity & wait" "trap : TERM INT; sleep infinity & wait"
} }
} }
}, },
RestartPolicy = "Never" RestartPolicy = "Never"

View File

@@ -17,9 +17,9 @@ metadata:
name: foo name: foo
"; ";
var obj = Yaml.LoadFromString<V1Pod>(content); var obj = Yaml.LoadFromString<V1Pod>(content);
Assert.Equal("foo", obj.Metadata.Name); Assert.Equal("foo", obj.Metadata.Name);
} }
[Fact] [Fact]
@@ -89,10 +89,10 @@ spec:
- name: cpu-demo-ctr - name: cpu-demo-ctr
image: vish/stress image: vish/stress
resources: resources:
limits: limits:
cpu: ""1"" cpu: ""1""
requests: requests:
cpu: ""0.5"" cpu: ""0.5""
args: args:
- -cpus - -cpus
- ""2"""; - ""2""";