diff --git a/Tools/packages.config b/Tools/packages.config
index 01fee594627..abc3ac2be5f 100644
--- a/Tools/packages.config
+++ b/Tools/packages.config
@@ -7,6 +7,6 @@
-
+
diff --git a/src/NHibernate.Test/Async/ExpressionTest/QueryByExampleTest.cs b/src/NHibernate.Test/Async/ExpressionTest/QueryByExampleTest.cs
index cd1893553da..9e4036a8063 100644
--- a/src/NHibernate.Test/Async/ExpressionTest/QueryByExampleTest.cs
+++ b/src/NHibernate.Test/Async/ExpressionTest/QueryByExampleTest.cs
@@ -17,7 +17,6 @@
namespace NHibernate.Test.ExpressionTest
{
using System.Threading.Tasks;
- using System.Threading;
[TestFixture]
public class QueryByExampleTestAsync : TestCase
{
@@ -150,30 +149,6 @@ public async Task TestExcludingQBEAsync()
}
}
- private async Task InitDataAsync(CancellationToken cancellationToken = default(CancellationToken))
- {
- using (ISession s = OpenSession())
- {
- Componentizable master = GetMaster("hibernate", "ORM tool", "ORM tool1");
- await (s.SaveAsync(master, cancellationToken));
- await (s.FlushAsync(cancellationToken));
- }
-
- using (ISession s = OpenSession())
- {
- Componentizable master = GetMaster("hibernate", "open source", "open source1");
- await (s.SaveAsync(master, cancellationToken));
- await (s.FlushAsync(cancellationToken));
- }
-
- using (ISession s = OpenSession())
- {
- Componentizable master = GetMaster("hibernate", null, null);
- await (s.SaveAsync(master, cancellationToken));
- await (s.FlushAsync(cancellationToken));
- }
- }
-
private void InitData()
{
using (ISession s = OpenSession())
@@ -198,16 +173,6 @@ private void InitData()
}
}
- private async Task DeleteDataAsync(CancellationToken cancellationToken = default(CancellationToken))
- {
- using (ISession s = OpenSession())
- using (ITransaction t = s.BeginTransaction())
- {
- await (s.DeleteAsync("from Componentizable", cancellationToken));
- await (t.CommitAsync(cancellationToken));
- }
- }
-
private void DeleteData()
{
using (ISession s = OpenSession())
diff --git a/src/NHibernate.Test/Async/NHSpecificTest/NH1507/Fixture.cs b/src/NHibernate.Test/Async/NHSpecificTest/NH1507/Fixture.cs
index 1fb0778ed9c..48a864ef62c 100644
--- a/src/NHibernate.Test/Async/NHSpecificTest/NH1507/Fixture.cs
+++ b/src/NHibernate.Test/Async/NHSpecificTest/NH1507/Fixture.cs
@@ -16,7 +16,6 @@
namespace NHibernate.Test.NHSpecificTest.NH1507
{
using System.Threading.Tasks;
- using System.Threading;
[TestFixture]
public class FixtureAsync : BugTestCase
{
@@ -35,54 +34,6 @@ protected override void OnTearDown()
CleanupData();
}
- private async Task CreateDataAsync(CancellationToken cancellationToken = default(CancellationToken))
- {
- //Employee
- var emp = new Employee
- {
- Address = "Zombie street",
- City = "Bitonto",
- PostalCode = "66666",
- FirstName = "tomb",
- LastName = "mutilated"
- };
-
- //and his related orders
- var order = new Order
- {OrderDate = DateTime.Now, Employee = emp, ShipAddress = "dead zone 1", ShipCountry = "Deadville"};
-
- var order2 = new Order
- {OrderDate = DateTime.Now, Employee = emp, ShipAddress = "dead zone 2", ShipCountry = "Deadville"};
-
- //Employee with no related orders but with same PostalCode
- var emp2 = new Employee
- {
- Address = "Gut street",
- City = "Mariotto",
- Country = "Arised",
- PostalCode = "66666",
- FirstName = "carcass",
- LastName = "purulent"
- };
-
- //Order with no related employee but with same ShipCountry
- var order3 = new Order {OrderDate = DateTime.Now, ShipAddress = "dead zone 2", ShipCountry = "Deadville"};
-
- using (ISession session = OpenSession())
- {
- using (ITransaction tx = session.BeginTransaction())
- {
- await (session.SaveAsync(emp, cancellationToken));
- await (session.SaveAsync(emp2, cancellationToken));
- await (session.SaveAsync(order, cancellationToken));
- await (session.SaveAsync(order2, cancellationToken));
- await (session.SaveAsync(order3, cancellationToken));
-
- await (tx.CommitAsync(cancellationToken));
- }
- }
- }
-
private void CreateData()
{
//Employee
@@ -131,23 +82,6 @@ private void CreateData()
}
}
- private async Task CleanupDataAsync(CancellationToken cancellationToken = default(CancellationToken))
- {
- using (ISession session = OpenSession())
- {
- using (ITransaction tx = session.BeginTransaction())
- {
- //delete empolyee and related orders
- await (session.DeleteAsync("from Employee ee where ee.PostalCode = '66666'", cancellationToken));
-
- //delete order not related to employee
- await (session.DeleteAsync("from Order oo where oo.ShipCountry = 'Deadville'", cancellationToken));
-
- await (tx.CommitAsync(cancellationToken));
- }
- }
- }
-
private void CleanupData()
{
using (ISession session = OpenSession())
diff --git a/src/NHibernate.Test/Async/NHSpecificTest/NH1553/MsSQL/SnapshotIsolationUpdateConflictTest.cs b/src/NHibernate.Test/Async/NHSpecificTest/NH1553/MsSQL/SnapshotIsolationUpdateConflictTest.cs
index 51b512ca1a9..ad82ceb33c0 100644
--- a/src/NHibernate.Test/Async/NHSpecificTest/NH1553/MsSQL/SnapshotIsolationUpdateConflictTest.cs
+++ b/src/NHibernate.Test/Async/NHSpecificTest/NH1553/MsSQL/SnapshotIsolationUpdateConflictTest.cs
@@ -159,17 +159,6 @@ protected override bool AppliesTo(ISessionFactoryImplementor factory)
return factory.ConnectionProvider.Driver is SqlClientDriver;
}
- private async Task SetAllowSnapshotIsolationAsync(bool on, CancellationToken cancellationToken = default(CancellationToken))
- {
- using (ISession session = OpenSession())
- {
- var command = session.Connection.CreateCommand();
- command.CommandText = "ALTER DATABASE " + session.Connection.Database + " set allow_snapshot_isolation "
- + (on ? "on" : "off");
- await (command.ExecuteNonQueryAsync(cancellationToken));
- }
- }
-
private void SetAllowSnapshotIsolation(bool on)
{
using (ISession session = OpenSession())
diff --git a/src/NHibernate.Test/Async/NHSpecificTest/NH1792/Fixture.cs b/src/NHibernate.Test/Async/NHSpecificTest/NH1792/Fixture.cs
index e82d4a880f2..1d5b3022887 100644
--- a/src/NHibernate.Test/Async/NHSpecificTest/NH1792/Fixture.cs
+++ b/src/NHibernate.Test/Async/NHSpecificTest/NH1792/Fixture.cs
@@ -16,7 +16,6 @@
namespace NHibernate.Test.NHSpecificTest.NH1792
{
using System.Threading.Tasks;
- using System.Threading;
[TestFixture]
public class FixtureAsync : BugTestCase
{
@@ -25,22 +24,6 @@ protected override void OnTearDown()
DeleteAll();
}
- ///
- /// Deletes all the product entities from the persistence medium
- ///
- /// A cancellation token that can be used to cancel the work
- private async Task DeleteAllAsync(CancellationToken cancellationToken = default(CancellationToken))
- {
- using (ISession session = OpenSession())
- {
- using (ITransaction trans = session.BeginTransaction())
- {
- await (session.DeleteAsync("from Product", cancellationToken));
- await (trans.CommitAsync(cancellationToken));
- }
- }
- }
-
///
/// Deletes all the product entities from the persistence medium
///
diff --git a/src/NHibernate.Test/Async/NHSpecificTest/NH2302/Fixture.cs b/src/NHibernate.Test/Async/NHSpecificTest/NH2302/Fixture.cs
index 759fe34b3e7..df16c52023c 100644
--- a/src/NHibernate.Test/Async/NHSpecificTest/NH2302/Fixture.cs
+++ b/src/NHibernate.Test/Async/NHSpecificTest/NH2302/Fixture.cs
@@ -17,7 +17,6 @@
namespace NHibernate.Test.NHSpecificTest.NH2302
{
using System.Threading.Tasks;
- using System.Threading;
[TestFixture]
public class FixtureAsync : BugTestCase
{
@@ -197,16 +196,6 @@ public async Task BlobWithoutLengthAsync()
}
}
- private async Task CleanUpAsync(CancellationToken cancellationToken = default(CancellationToken))
- {
- using (ISession session = OpenSession())
- using (ITransaction tx = session.BeginTransaction())
- {
- await (session.DeleteAsync("from StringLengthEntity", cancellationToken));
- await (tx.CommitAsync(cancellationToken));
- }
- }
-
private void CleanUp()
{
using (ISession session = OpenSession())
diff --git a/src/NHibernate.Test/Async/NHSpecificTest/NH2583/ManualTestFixture.cs b/src/NHibernate.Test/Async/NHSpecificTest/NH2583/ManualTestFixture.cs
index c459727b5af..e3a1afd2f45 100644
--- a/src/NHibernate.Test/Async/NHSpecificTest/NH2583/ManualTestFixture.cs
+++ b/src/NHibernate.Test/Async/NHSpecificTest/NH2583/ManualTestFixture.cs
@@ -305,18 +305,6 @@ protected override void OnTearDown()
}
}
- private static Task DeleteAllAsync(ISession session, CancellationToken cancellationToken = default(CancellationToken))
- {
- try
- {
- return session.CreateQuery("delete from " + typeof(T).Name).ExecuteUpdateAsync(cancellationToken);
- }
- catch (Exception ex)
- {
- return Task.FromException