* Stylecop Rules and Fixes
This commit is contained in:
Qstick
2020-01-03 07:49:24 -05:00
committed by GitHub
parent 63d669178d
commit f77a2feeef
1307 changed files with 8704 additions and 7404 deletions
@@ -26,7 +26,6 @@ namespace NzbDrone.Common.Test.CacheTests
_cachedString.Get("Test", _worker.GetString);
_worker.HitCount.Should().Be(1);
}
[Test]
@@ -38,7 +37,6 @@ namespace NzbDrone.Common.Test.CacheTests
first.Should().Be(second);
}
[Test]
public void should_be_able_to_update_key()
{
@@ -48,7 +46,6 @@ namespace NzbDrone.Common.Test.CacheTests
_cachedString.Find("Key").Should().Be("New");
}
[Test]
public void should_be_able_to_remove_key()
{
@@ -70,7 +67,6 @@ namespace NzbDrone.Common.Test.CacheTests
{
int hitCount = 0;
for (int i = 0; i < 10; i++)
{
_cachedString.Get("key", () =>
@@ -84,7 +80,7 @@ namespace NzbDrone.Common.Test.CacheTests
}
[Test]
[Platform(Exclude="MacOsX")]
[Platform(Exclude = "MacOsX")]
public void should_honor_ttl()
{
int hitCount = 0;
@@ -92,11 +88,13 @@ namespace NzbDrone.Common.Test.CacheTests
for (int i = 0; i < 10; i++)
{
_cachedString.Get("key", () =>
{
hitCount++;
return null;
}, TimeSpan.FromMilliseconds(300));
_cachedString.Get("key",
() =>
{
hitCount++;
return null;
},
TimeSpan.FromMilliseconds(300));
Thread.Sleep(100);
}
@@ -106,7 +104,7 @@ namespace NzbDrone.Common.Test.CacheTests
[Test]
[Retry(3)]
[Platform(Exclude="MacOsX")]
[Platform(Exclude = "MacOsX")]
public void should_clear_expired_when_they_expire()
{
int hitCount = 0;
@@ -114,11 +112,13 @@ namespace NzbDrone.Common.Test.CacheTests
for (int i = 0; i < 10; i++)
{
_cachedString.Get("key", () =>
{
hitCount++;
return null;
}, TimeSpan.FromMilliseconds(300));
_cachedString.Get("key",
() =>
{
hitCount++;
return null;
},
TimeSpan.FromMilliseconds(300));
Thread.Sleep(100);
}