Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSenganal T <senga@mono-cvs.ximian.com>2005-09-21 18:27:58 +0400
committerSenganal T <senga@mono-cvs.ximian.com>2005-09-21 18:27:58 +0400
commit694cd01513b763d79b2d55c986b911fede18a1fe (patch)
tree0d4adb25c758fb031f93751d5a19f48ab04cd49b /mcs/class/System.Data/Test
parenta4aafd6734729d83c817892e3565cf4ba64f9626 (diff)
In Mono.Data.Tds:
* Mono.Data.Tds.Protocol/Tds.cs: - Modified the way Server Version number is calculated - Added a new varaible to remember the original database connected to and to reset the Database property when the connection to database is closed. * Mono.Data.Tds.Protocol/Tds70.cs: modified Reset() to Call the Reset() of base class which in turn resets the database name. In System.Data/Test/ProviderTests/System.Data.SqlClient: * SqlConnectionTest.cs: removed some hardcoded database names in DatabasePropertyTest (). In System.Data/System.Data.SqlClient: * SqlConnection.cs : - Set the correct Default Values for Parameters. - Added Argument Checks (where missing) for the Properties and throw the correct exception on error. - Modified SetDefaultParameters() to make sure that the parameters are all reset to default values everytime it is called. - Modified SetProperties() to take into account the order of the keywords in the ConnectionString. svn path=/trunk/mcs/; revision=50377
Diffstat (limited to 'mcs/class/System.Data/Test')
-rw-r--r--mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/ChangeLog5
-rw-r--r--mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/SqlConnectionTest.cs7
2 files changed, 9 insertions, 3 deletions
diff --git a/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/ChangeLog b/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/ChangeLog
index 4c8da99165b..fc0f8a50a4f 100644
--- a/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/ChangeLog
+++ b/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/ChangeLog
@@ -1,3 +1,8 @@
+2005-09-21 Senganal T <tsenganal@novell.com>
+
+ * SqlConnectionTest.cs: removed some hardcoded database names
+ in DatabasePropertyTest ().
+
2005-09-16 Senganal T <tsenganal@novell.com>
* SqlCommandTest.cs: added more testcases for connected mode
diff --git a/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/SqlConnectionTest.cs b/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/SqlConnectionTest.cs
index 7f22718c132..5b5953befda 100644
--- a/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/SqlConnectionTest.cs
+++ b/mcs/class/System.Data/Test/ProviderTests/System.Data.SqlClient/SqlConnectionTest.cs
@@ -123,7 +123,7 @@ namespace MonoTests.System.Data
Assert.AreEqual (300, conn.ConnectionTimeout,
"## The last set value shud be taken");
conn = new SqlConnection (
- "Connection Timeout=1000;Timeout=200$0;Connect Timeout=3000");
+ "Connection Timeout=1000;Timeout=2000;Connect Timeout=3000");
Assert.AreEqual (3000, conn.ConnectionTimeout,
"## The last set value shud be taken");
@@ -485,6 +485,7 @@ namespace MonoTests.System.Data
public void DatabasePropertyTest ()
{
conn = new SqlConnection (connectionString);
+ string database = conn.Database ;
// Test if database property is updated when a query changes database
conn.Open ();
@@ -493,13 +494,13 @@ namespace MonoTests.System.Data
Assert.AreEqual ("mono-test", conn.Database,
"#1 DATABASE name shud change if query changes the db");
conn.Close ();
- Assert.AreEqual ("monotest", conn.Database,
+ Assert.AreEqual (database, conn.Database,
"#2 Shud be back to default value");
// Test if the database property is reset on re-opening the connection
conn.ConnectionString = connectionString;
conn.Open ();
- Assert.AreEqual ("monotest", conn.Database,
+ Assert.AreEqual (database, conn.Database,
"#3 Shud be back to original value");
conn.Close ();
}