-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
59 changed files
with
639 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
AsyncConverter.Tests/Highlightings/ConfigureAwait/ConfigureAwaitOnTestTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
using AsyncConverter.Settings.General; | ||
using JetBrains.ReSharper.TestFramework; | ||
|
||
namespace AsyncConverter.Tests.Highlightings | ||
{ | ||
[TestSetting(typeof(GeneralSettings), nameof(GeneralSettings.ExcludeTestMethodsFromConfigureAwait), false)] | ||
public class ConfigureAwaitOnTestTests : HighlightingsTestsBase | ||
{ | ||
protected override string Folder => "ConfigureAwait/OnTest"; | ||
} | ||
} |
7 changes: 7 additions & 0 deletions
7
AsyncConverter.Tests/Highlightings/ConfigureAwait/ConfigureAwaitTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
namespace AsyncConverter.Tests.Highlightings | ||
{ | ||
public class ConfigureAwaitTests : HighlightingsTestsBase | ||
{ | ||
protected override string Folder => "ConfigureAwait/Common"; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
21 changes: 21 additions & 0 deletions
21
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/Common/MsTestAttr.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Microsoft.VisualStudio.TestTools.UnitTesting; | ||
public class Class | ||
{ | ||
[TestMethod] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace Microsoft.VisualStudio.TestTools.UnitTesting | ||
{ | ||
public class TestMethodAttribute : Attribute | ||
{ } | ||
} |
22 changes: 22 additions & 0 deletions
22
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/Common/MsTestAttr.cs.gold
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Microsoft.VisualStudio.TestTools.UnitTesting; | ||
public class Class | ||
{ | ||
[TestMethod] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace Microsoft.VisualStudio.TestTools.UnitTesting | ||
{ | ||
public class TestMethodAttribute : Attribute | ||
{ } | ||
} | ||
--------------------------------------------------------- |
21 changes: 21 additions & 0 deletions
21
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/Common/WithAttributeOnClass.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using NUnit.Framework; | ||
public class Class | ||
{ | ||
[Test] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace NUnit.Framework | ||
{ | ||
public class TestAttribute : Attribute | ||
{ } | ||
} |
23 changes: 23 additions & 0 deletions
23
...onverter.Tests/Test/Data/Highlightings/ConfigureAwait/Common/WithAttributeOnClass.cs.gold
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using NUnit.Framework; | ||
public class Class | ||
{ | ||
[Test] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace NUnit.Framework | ||
{ | ||
public class TestAttribute : Attribute | ||
{ } | ||
} | ||
|
||
--------------------------------------------------------- |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
21 changes: 21 additions & 0 deletions
21
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/MsTestAttr.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Microsoft.VisualStudio.TestTools.UnitTesting; | ||
public class Class | ||
{ | ||
[TestMethod] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace Microsoft.VisualStudio.TestTools.UnitTesting | ||
{ | ||
public class TestMethodAttribute : Attribute | ||
{ } | ||
} |
23 changes: 23 additions & 0 deletions
23
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/MsTestAttr.cs.gold
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Microsoft.VisualStudio.TestTools.UnitTesting; | ||
public class Class | ||
{ | ||
[TestMethod] | ||
public async Task Test() | ||
{ | ||
|await Task.Delay(1000)|(0); | ||
} | ||
} | ||
} | ||
|
||
namespace Microsoft.VisualStudio.TestTools.UnitTesting | ||
{ | ||
public class TestMethodAttribute : Attribute | ||
{ } | ||
} | ||
--------------------------------------------------------- | ||
(0): ReSharper Warning: (T) 'If await not configured it may cause deadlock, if this code will be call synchronously' (E) 'Await not configured' |
21 changes: 21 additions & 0 deletions
21
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/NUnitTestAttr.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using NUnit.Framework; | ||
public class Class | ||
{ | ||
[Test] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace NUnit.Framework | ||
{ | ||
public class TestAttribute : Attribute | ||
{ } | ||
} |
23 changes: 23 additions & 0 deletions
23
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/NUnitTestAttr.cs.gold
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using NUnit.Framework; | ||
public class Class | ||
{ | ||
[Test] | ||
public async Task Test() | ||
{ | ||
|await Task.Delay(1000)|(0); | ||
} | ||
} | ||
} | ||
|
||
namespace NUnit.Framework | ||
{ | ||
public class TestAttribute : Attribute | ||
{ } | ||
} | ||
--------------------------------------------------------- | ||
(0): ReSharper Warning: (T) 'If await not configured it may cause deadlock, if this code will be call synchronously' (E) 'Await not configured' |
21 changes: 21 additions & 0 deletions
21
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/NUnitTestCaseAttr.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using NUnit.Framework; | ||
public class Class | ||
{ | ||
[TestCase] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace NUnit.Framework | ||
{ | ||
public class TestCaseAttribute : Attribute | ||
{ } | ||
} |
23 changes: 23 additions & 0 deletions
23
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/NUnitTestCaseAttr.cs.gold
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using NUnit.Framework; | ||
public class Class | ||
{ | ||
[TestCase] | ||
public async Task Test() | ||
{ | ||
|await Task.Delay(1000)|(0); | ||
} | ||
} | ||
} | ||
|
||
namespace NUnit.Framework | ||
{ | ||
public class TestCaseAttribute : Attribute | ||
{ } | ||
} | ||
--------------------------------------------------------- | ||
(0): ReSharper Warning: (T) 'If await not configured it may cause deadlock, if this code will be call synchronously' (E) 'Await not configured' |
21 changes: 21 additions & 0 deletions
21
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/XunitFactAttr.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Xunit; | ||
public class Class | ||
{ | ||
[Fact] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace Xunit | ||
{ | ||
public class FactAttribute : Attribute | ||
{ } | ||
} |
23 changes: 23 additions & 0 deletions
23
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/XunitFactAttr.cs.gold
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Xunit; | ||
public class Class | ||
{ | ||
[Fact] | ||
public async Task Test() | ||
{ | ||
|await Task.Delay(1000)|(0); | ||
} | ||
} | ||
} | ||
|
||
namespace Xunit | ||
{ | ||
public class FactAttribute : Attribute | ||
{ } | ||
} | ||
--------------------------------------------------------- | ||
(0): ReSharper Warning: (T) 'If await not configured it may cause deadlock, if this code will be call synchronously' (E) 'Await not configured' |
21 changes: 21 additions & 0 deletions
21
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/XunitTheoryAttr.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Xunit; | ||
public class Class | ||
{ | ||
[Theory] | ||
public async Task Test() | ||
{ | ||
await Task.Delay(1000); | ||
} | ||
} | ||
} | ||
|
||
namespace Xunit | ||
{ | ||
public class TheoryAttribute : Attribute | ||
{ } | ||
} |
23 changes: 23 additions & 0 deletions
23
AsyncConverter.Tests/Test/Data/Highlightings/ConfigureAwait/OnTest/XunitTheoryAttr.cs.gold
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using System; | ||
using System.Threading.Tasks; | ||
|
||
namespace AsyncConverter.Tests.Test.Data.FixReturnValueToTaskTests | ||
{ | ||
using Xunit; | ||
public class Class | ||
{ | ||
[Theory] | ||
public async Task Test() | ||
{ | ||
|await Task.Delay(1000)|(0); | ||
} | ||
} | ||
} | ||
|
||
namespace Xunit | ||
{ | ||
public class TheoryAttribute : Attribute | ||
{ } | ||
} | ||
--------------------------------------------------------- | ||
(0): ReSharper Warning: (T) 'If await not configured it may cause deadlock, if this code will be call synchronously' (E) 'Await not configured' |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Oops, something went wrong.