Share via


DatabaseTestService.DeployDatabaseProject Method (String, String, String, String)

Deploys a database project to the database specified in the referenced configuration.

Namespace:  Microsoft.VisualStudio.TeamSystem.Data.UnitTesting
Assembly:  Microsoft.VisualStudio.TeamSystem.Data.UnitTesting (in Microsoft.VisualStudio.TeamSystem.Data.UnitTesting.dll)

Syntax

'Declaration
Protected Shared Sub DeployDatabaseProject ( _
    databaseProjectFileName As String, _
    configuration As String, _
    providerInvariantName As String, _
    connectionString As String _
)
'Usage
Dim databaseProjectFileName As String
Dim configuration As String
Dim providerInvariantName As String
Dim connectionString As String

DatabaseTestService.DeployDatabaseProject(databaseProjectFileName, _
    configuration, providerInvariantName, _
    connectionString)
protected static void DeployDatabaseProject(
    string databaseProjectFileName,
    string configuration,
    string providerInvariantName,
    string connectionString
)
protected:
static void DeployDatabaseProject(
    String^ databaseProjectFileName, 
    String^ configuration, 
    String^ providerInvariantName, 
    String^ connectionString
)
protected static function DeployDatabaseProject(
    databaseProjectFileName : String, 
    configuration : String, 
    providerInvariantName : String, 
    connectionString : String
)

Parameters

  • databaseProjectFileName
    Type: System.String
    The path to the database project file.
  • configuration
    Type: System.String
    The solution build configuration that should be used when executing the deployment MSBuild task.
  • connectionString
    Type: System.String
    The connection string for the target database. This must be a connection string to a SQL database.

Remarks

This method deploys a database project if the necessary information has been added to the app.config file using the classes provided in the Microsoft.VisualStudio.TeamSystem.Data.UnitTesting.Configuration namespace.

A privileged connection context is used to deploy the database.

Permissions

See Also

Reference

DatabaseTestService Class

DatabaseTestService Members

DeployDatabaseProject Overload

Microsoft.VisualStudio.TeamSystem.Data.UnitTesting Namespace