Export (0) Print
Expand All

DataSourceAttribute.ProviderInvariantName Property

Gets a value representing the data provider of the data source.

Namespace:  Microsoft.VisualStudio.TestTools.UnitTesting
Assembly:  Microsoft.VisualStudio.QualityTools.UnitTestFramework (in Microsoft.VisualStudio.QualityTools.UnitTestFramework.dll)

public string ProviderInvariantName { get; }

Property Value

Type: System.String
The data provider name. If a data provider was not designated at object initialization, the default provider of System.Data.OleDb will be returned.

Different providers use different connection strings.

A list of possible data providers are:

  • .NET Framework Data Provider for OLE DB (for Access and other Jet databases).

  • .NET Framework Data Provider for ODBC.

  • .NET Framework Data Provider for SQL Server (to connect to Microsoft SQL Server 7.0, 2000, 2005, and local Microsoft SQL Server instances including Microsoft SQL Express).

  • .NET Framework Data Provider to connect to SQL Server 2005 Mobile Edition.

  • .NET Framework Data Provider for Oracle (to connect to Oracle 7.3, 8i, or 9i).

To set this attribute property, see How to: Configure a Data-Driven Unit Test.

Show:
© 2015 Microsoft