new DataContext("DbLinqConnectionType=");\r
}\r
\r
+ [Test, ExpectedException(typeof(ArgumentException))]\r
+ public void Ctor_ConnectionString_DbLinqConnectionType_Empty2()\r
+ {\r
+ new DataContext("DbLinqConnectionType=;");\r
+ }\r
+\r
[Test, ExpectedException(typeof(ArgumentException))]\r
public void Ctor_ConnectionString_DbLinqConnectionType_Invalid()\r
{\r
new DataContext("DbLinqProvider=DbLinq.Sqlite.dll");\r
}\r
\r
+ [Test, ExpectedException(typeof(ArgumentNullException))]\r
+ public void Ctor_FileOrServerOrConnectionIsNull()\r
+ {\r
+ MappingSource mapping = new AttributeMappingSource();\r
+ string fileOrServerOrConnection = null;\r
+ new DataContext(fileOrServerOrConnection, mapping);\r
+ }\r
+\r
+ [Test, ExpectedException(typeof(ArgumentNullException))]\r
+ public void Ctor_MappingIsNull()\r
+ {\r
+ MappingSource mapping = null;\r
+ string fileOrServerOrConnection = null;\r
+ new DataContext("", mapping);\r
+ }\r
+\r
+#if !MONO_STRICT\r
+ [Test, ExpectedException(typeof(NotImplementedException))]\r
+ public void Ctor_FileOrServerOrConnectionIsFilename()\r
+ {\r
+ MappingSource mapping = new AttributeMappingSource();\r
+ string fileOrServerOrConnection = typeof(DataContextTest).Assembly.Location;\r
+ new DataContext(fileOrServerOrConnection, mapping);\r
+ }\r
+\r
+ [Test, ExpectedException(typeof(NotImplementedException))]\r
+ public void Ctor_FileOrServerOrConnectionIsServer()\r
+ {\r
+ MappingSource mapping = new AttributeMappingSource();\r
+ string fileOrServerOrConnection = "ThisIsAssumedToBeAServerName";\r
+ new DataContext(fileOrServerOrConnection, mapping);\r
+ }\r
+#endif\r
+\r
[Test]\r
public void Connection()\r
{\r