From 55efb3c65a6222bdb2d6b086b9b62b56c9b72e11 Mon Sep 17 00:00:00 2001 From: Chrissy LeMaire Date: Mon, 28 Oct 2024 14:43:16 +0100 Subject: [PATCH] install pip --- appveyor.yml | 3 ++ tests/Copy-DbaAgentAlert.Tests.ps1 | 36 ++++++++-------- tests/Copy-DbaAgentJob.Tests.ps1 | 37 ++++++++-------- tests/Copy-DbaAgentJobCategory.Tests.ps1 | 39 ++++++++--------- tests/Copy-DbaAgentOperator.Tests.ps1 | 34 +++++++-------- tests/Copy-DbaAgentProxy.Tests.ps1 | 34 +++++++-------- tests/Copy-DbaAgentSchedule.Tests.ps1 | 36 ++++++++-------- tests/Copy-DbaAgentServer.Tests.ps1 | 38 ++++++++--------- tests/Copy-DbaBackupDevice.Tests.ps1 | 32 +++++++------- tests/Copy-DbaCustomError.Tests.ps1 | 36 ++++++++-------- tests/Copy-DbaDataCollector.Tests.ps1 | 38 ++++++++--------- tests/Copy-DbaDbCertificate.Tests.ps1 | 40 +++++++++--------- tests/Copy-DbaDbMail.Tests.ps1 | 28 ++++++------- tests/Copy-DbaDbQueryStoreOption.Tests.ps1 | 36 ++++++++-------- tests/Copy-DbaEndpoint.Tests.ps1 | 34 +++++++-------- tests/Copy-DbaInstanceAudit.Tests.ps1 | 38 ++++++++--------- ...py-DbaInstanceAuditSpecification.Tests.ps1 | 36 ++++++++-------- tests/Copy-DbaInstanceTrigger.Tests.ps1 | 34 +++++++-------- tests/Copy-DbaLinkedServer.Tests.ps1 | 40 +++++++++--------- tests/Copy-DbaPolicyManagement.Tests.ps1 | 40 +++++++++--------- tests/Copy-DbaRegServer.Tests.ps1 | 34 +++++++-------- tests/Copy-DbaResourceGovernor.Tests.ps1 | 2 +- tests/Copy-DbaSpConfigure.Tests.ps1 | 32 +++++++------- tests/Copy-DbaSsisCatalog.Tests.ps1 | 42 +++++++++---------- tests/Copy-DbaStartupProcedure.Tests.ps1 | 34 +++++++-------- tests/Copy-DbaSystemDbUserObject.Tests.ps1 | 32 +++++++------- tests/Copy-DbaXESession.Tests.ps1 | 36 ++++++++-------- tests/Copy-DbaXESessionTemplate.Tests.ps1 | 22 +++++----- tests/Disable-DbaAgHadr.Tests.ps1 | 26 ++++++------ tests/Disable-DbaDbEncryption.Tests.ps1 | 26 ++++++------ ...isable-DbaForceNetworkEncryption.Tests.ps1 | 24 +++++------ tests/Disable-DbaHideInstance.Tests.ps1 | 24 +++++------ tests/Disable-DbaReplPublishing.Tests.ps1 | 26 ++++++------ tests/Disable-DbaStartupProcedure.Tests.ps1 | 28 ++++++------- tests/Disable-DbaTraceFlag.Tests.ps1 | 22 +++++----- tests/Disconnect-DbaInstance.Tests.ps1 | 22 +++++----- tests/Enable-DbaAgHadr.Tests.ps1 | 26 ++++++------ tests/Enable-DbaDbEncryption.Tests.ps1 | 32 +++++++------- tests/Enable-DbaFilestream.Tests.ps1 | 32 +++++++------- ...Enable-DbaForceNetworkEncryption.Tests.ps1 | 24 +++++------ tests/Enable-DbaHideInstance.Tests.ps1 | 24 +++++------ tests/Enable-DbaReplDistributor.Tests.ps1 | 28 ++++++------- tests/Enable-DbaReplPublishing.Tests.ps1 | 30 ++++++------- tests/Enable-DbaStartupProcedure.Tests.ps1 | 26 ++++++------ tests/Enable-DbaTraceFlag.Tests.ps1 | 22 +++++----- tests/Expand-DbaDbLogFile.Tests.ps1 | 42 +++++++++---------- tests/Export-DbaBinaryFile.Tests.ps1 | 42 +++++++++---------- tests/Export-DbaCredential.Tests.ps1 | 34 +++++++-------- 48 files changed, 740 insertions(+), 743 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index b2f56e6e17..9be8acd636 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -4,6 +4,7 @@ configuration: "Debug" build_script: - ps: Set-Service wuauserv -StartupType Manual #otherwise, choco command exits with code 1058 + - cmd: pip install aider-chat # Install aider-chat version: 2.1.{build} @@ -19,6 +20,8 @@ clone_depth: 100 # Set build info environment: + PYTHON: "C:\\Python39" # or specify the path to the latest Python version + PATH: "C:\\Python39;C:\\Python39\\Scripts;%PATH%" environment: development version: 2.1.$(appveyor_build_number) appveyor_rdp_password: 2odCuiKmYiem diff --git a/tests/Copy-DbaAgentAlert.Tests.ps1 b/tests/Copy-DbaAgentAlert.Tests.ps1 index 075cfffb58..9b4b2ff122 100644 --- a/tests/Copy-DbaAgentAlert.Tests.ps1 +++ b/tests/Copy-DbaAgentAlert.Tests.ps1 @@ -5,25 +5,25 @@ param( ) Describe "Copy-DbaAgentAlert" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaAgentAlert - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Alert", - "ExcludeAlert", - "IncludeDefaults", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaAgentAlert + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Alert", + "ExcludeAlert", + "IncludeDefaults", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaAgentJob.Tests.ps1 b/tests/Copy-DbaAgentJob.Tests.ps1 index 9e466da013..8dc92ea0c8 100644 --- a/tests/Copy-DbaAgentJob.Tests.ps1 +++ b/tests/Copy-DbaAgentJob.Tests.ps1 @@ -6,6 +6,23 @@ param( Describe "Copy-DbaAgentJob" -Tag "IntegrationTests" { BeforeAll { + $command = Get-Command Copy-DbaAgentJob + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Job", + "ExcludeJob", + "DisableOnSource", + "DisableOnDestination", + "Force", + "InputObject", + "EnableException", + "Confirm", + "WhatIf" + ) $null = New-DbaAgentJob -SqlInstance $TestConfig.instance2 -Job dbatoolsci_copyjob $null = New-DbaAgentJob -SqlInstance $TestConfig.instance2 -Job dbatoolsci_copyjob_disabled $sourcejobs = Get-DbaAgentJob -SqlInstance $TestConfig.instance2 @@ -17,26 +34,6 @@ Describe "Copy-DbaAgentJob" -Tag "IntegrationTests" { } Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaAgentJob - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Job", - "ExcludeJob", - "DisableOnSource", - "DisableOnDestination", - "Force", - "InputObject", - "EnableException", - "Confirm", - "WhatIf" - ) - } - It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaAgentJobCategory.Tests.ps1 b/tests/Copy-DbaAgentJobCategory.Tests.ps1 index 79ef6ca357..5eb3b354ec 100644 --- a/tests/Copy-DbaAgentJobCategory.Tests.ps1 +++ b/tests/Copy-DbaAgentJobCategory.Tests.ps1 @@ -6,33 +6,30 @@ param( Describe "Copy-DbaAgentJobCategory" -Tag "IntegrationTests" { BeforeAll { - $null = New-DbaAgentJobCategory -SqlInstance $TestConfig.instance2 -Category 'dbatoolsci test category' + $command = Get-Command Copy-DbaAgentJobCategory + + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "CategoryType", + "JobCategory", + "AgentCategory", + "OperatorCategory", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) } + AfterAll { $null = Remove-DbaAgentJobCategory -SqlInstance $TestConfig.instance2 -Category 'dbatoolsci test category' -Confirm:$false } Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaAgentJobCategory - - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "CategoryType", - "JobCategory", - "AgentCategory", - "OperatorCategory", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } - It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaAgentOperator.Tests.ps1 b/tests/Copy-DbaAgentOperator.Tests.ps1 index 846e46d8b1..2b2824c439 100644 --- a/tests/Copy-DbaAgentOperator.Tests.ps1 +++ b/tests/Copy-DbaAgentOperator.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaAgentOperator" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaAgentOperator - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Operator", - "ExcludeOperator", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaAgentOperator + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Operator", + "ExcludeOperator", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaAgentProxy.Tests.ps1 b/tests/Copy-DbaAgentProxy.Tests.ps1 index 28ac1b9bdc..cb5bcc317a 100644 --- a/tests/Copy-DbaAgentProxy.Tests.ps1 +++ b/tests/Copy-DbaAgentProxy.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaAgentProxy" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaAgentProxy - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "ProxyAccount", - "ExcludeProxyAccount", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaAgentProxy + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "ProxyAccount", + "ExcludeProxyAccount", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaAgentSchedule.Tests.ps1 b/tests/Copy-DbaAgentSchedule.Tests.ps1 index 2f0bbaa7d2..7bf8192b13 100644 --- a/tests/Copy-DbaAgentSchedule.Tests.ps1 +++ b/tests/Copy-DbaAgentSchedule.Tests.ps1 @@ -5,25 +5,25 @@ param( ) Describe "Copy-DbaAgentSchedule" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaAgentSchedule - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Schedule", - "Id", - "InputObject", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaAgentSchedule + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Schedule", + "Id", + "InputObject", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaAgentServer.Tests.ps1 b/tests/Copy-DbaAgentServer.Tests.ps1 index 24814a4ae1..b33c62b17c 100644 --- a/tests/Copy-DbaAgentServer.Tests.ps1 +++ b/tests/Copy-DbaAgentServer.Tests.ps1 @@ -5,25 +5,25 @@ param( ) Describe "Copy-DbaAgentServer" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaAgentServer - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "DisableJobsOnDestination", - "DisableJobsOnSource", - "ExcludeServerProperties", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaAgentServer + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "DisableJobsOnDestination", + "DisableJobsOnSource", + "ExcludeServerProperties", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -33,4 +33,4 @@ Describe "Copy-DbaAgentServer" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasParams | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaBackupDevice.Tests.ps1 b/tests/Copy-DbaBackupDevice.Tests.ps1 index 49287fa22a..6619ff437a 100644 --- a/tests/Copy-DbaBackupDevice.Tests.ps1 +++ b/tests/Copy-DbaBackupDevice.Tests.ps1 @@ -7,23 +7,23 @@ param( Write-Host -Object "Running $PSCommandPath" -ForegroundColor Cyan Describe "Copy-DbaBackupDevice" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaBackupDevice - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "BackupDevice", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaBackupDevice + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "BackupDevice", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaCustomError.Tests.ps1 b/tests/Copy-DbaCustomError.Tests.ps1 index 76a8f117d3..529c21a66a 100644 --- a/tests/Copy-DbaCustomError.Tests.ps1 +++ b/tests/Copy-DbaCustomError.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaCustomError" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaCustomError - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "CustomError", - "ExcludeCustomError", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaCustomError + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "CustomError", + "ExcludeCustomError", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -77,4 +77,4 @@ Describe "Copy-DbaCustomError" -Tag "IntegrationTests" { $results.ID | Should -Contain 60000 } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaDataCollector.Tests.ps1 b/tests/Copy-DbaDataCollector.Tests.ps1 index fbac8bf06e..bcb0bc2879 100644 --- a/tests/Copy-DbaDataCollector.Tests.ps1 +++ b/tests/Copy-DbaDataCollector.Tests.ps1 @@ -7,25 +7,25 @@ param( Write-Host -Object "Running $PSCommandPath" -ForegroundColor Cyan Describe "Copy-DbaDataCollector" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaDataCollector - $expected = $TestConfig.CommonParameters - $expected += @( - 'Source', - 'SourceSqlCredential', - 'Destination', - 'DestinationSqlCredential', - 'CollectionSet', - 'ExcludeCollectionSet', - 'NoServerReconfig', - 'Force', - 'EnableException', - 'Confirm', - 'WhatIf' - ) - } + BeforeAll { + $command = Get-Command Copy-DbaDataCollector + $expected = $TestConfig.CommonParameters + $expected += @( + 'Source', + 'SourceSqlCredential', + 'Destination', + 'DestinationSqlCredential', + 'CollectionSet', + 'ExcludeCollectionSet', + 'NoServerReconfig', + 'Force', + 'EnableException', + 'Confirm', + 'WhatIf' + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -35,4 +35,4 @@ Describe "Copy-DbaDataCollector" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaDbCertificate.Tests.ps1 b/tests/Copy-DbaDbCertificate.Tests.ps1 index c833edd252..05ef7d7349 100644 --- a/tests/Copy-DbaDbCertificate.Tests.ps1 +++ b/tests/Copy-DbaDbCertificate.Tests.ps1 @@ -5,27 +5,27 @@ param( ) Describe "Copy-DbaDbCertificate" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaDbCertificate - $expected = $TestConfig.CommonParameters - $expected += @( - 'Source', - 'SourceSqlCredential', - 'Destination', - 'DestinationSqlCredential', - 'Database', - 'ExcludeDatabase', - 'Certificate', - 'ExcludeCertificate', - 'SharedPath', - 'MasterKeyPassword', - 'EncryptionPassword', - 'DecryptionPassword', - 'EnableException' - ) - } + BeforeAll { + $command = Get-Command Copy-DbaDbCertificate + $expected = $TestConfig.CommonParameters + $expected += @( + 'Source', + 'SourceSqlCredential', + 'Destination', + 'DestinationSqlCredential', + 'Database', + 'ExcludeDatabase', + 'Certificate', + 'ExcludeCertificate', + 'SharedPath', + 'MasterKeyPassword', + 'EncryptionPassword', + 'DecryptionPassword', + 'EnableException' + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaDbMail.Tests.ps1 b/tests/Copy-DbaDbMail.Tests.ps1 index 768cbdd878..c9de445b5b 100644 --- a/tests/Copy-DbaDbMail.Tests.ps1 +++ b/tests/Copy-DbaDbMail.Tests.ps1 @@ -5,21 +5,21 @@ param( ) Describe "Copy-DbaDbMail" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaDbMail - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "Destination", - "Type", - "SourceSqlCredential", - "DestinationSqlCredential", - "Force", - "EnableException" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaDbMail + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "Destination", + "Type", + "SourceSqlCredential", + "DestinationSqlCredential", + "Force", + "EnableException" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaDbQueryStoreOption.Tests.ps1 b/tests/Copy-DbaDbQueryStoreOption.Tests.ps1 index 8ff4f014d7..3c565f9b3c 100644 --- a/tests/Copy-DbaDbQueryStoreOption.Tests.ps1 +++ b/tests/Copy-DbaDbQueryStoreOption.Tests.ps1 @@ -7,25 +7,25 @@ param( Write-Host -Object "Running $PSCommandPath" -ForegroundColor Cyan Describe "Copy-DbaDbQueryStoreOption" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaDbQueryStoreOption - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "SourceDatabase", - "Destination", - "DestinationSqlCredential", - "DestinationDatabase", - "Exclude", - "AllDatabases", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaDbQueryStoreOption + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "SourceDatabase", + "Destination", + "DestinationSqlCredential", + "DestinationDatabase", + "Exclude", + "AllDatabases", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaEndpoint.Tests.ps1 b/tests/Copy-DbaEndpoint.Tests.ps1 index 37444bf61f..d8d5fc7a1b 100644 --- a/tests/Copy-DbaEndpoint.Tests.ps1 +++ b/tests/Copy-DbaEndpoint.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaEndpoint" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaEndpoint - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Endpoint", - "ExcludeEndpoint", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaEndpoint + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Endpoint", + "ExcludeEndpoint", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaInstanceAudit.Tests.ps1 b/tests/Copy-DbaInstanceAudit.Tests.ps1 index 4b4c18d57b..182ccd2927 100644 --- a/tests/Copy-DbaInstanceAudit.Tests.ps1 +++ b/tests/Copy-DbaInstanceAudit.Tests.ps1 @@ -5,25 +5,25 @@ param( ) Describe "Copy-DbaInstanceAudit" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaInstanceAudit - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Audit", - "ExcludeAudit", - "Path", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaInstanceAudit + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Audit", + "ExcludeAudit", + "Path", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -33,4 +33,4 @@ Describe "Copy-DbaInstanceAudit" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaInstanceAuditSpecification.Tests.ps1 b/tests/Copy-DbaInstanceAuditSpecification.Tests.ps1 index 60c0fe818a..4d069cad5b 100644 --- a/tests/Copy-DbaInstanceAuditSpecification.Tests.ps1 +++ b/tests/Copy-DbaInstanceAuditSpecification.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaInstanceAuditSpecification" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaInstanceAuditSpecification - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "AuditSpecification", - "ExcludeAuditSpecification", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaInstanceAuditSpecification + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "AuditSpecification", + "ExcludeAuditSpecification", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -32,4 +32,4 @@ Describe "Copy-DbaInstanceAuditSpecification" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaInstanceTrigger.Tests.ps1 b/tests/Copy-DbaInstanceTrigger.Tests.ps1 index df3f93678b..08261ca0f7 100644 --- a/tests/Copy-DbaInstanceTrigger.Tests.ps1 +++ b/tests/Copy-DbaInstanceTrigger.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaInstanceTrigger" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaInstanceTrigger - $expected = $TestConfig.CommonParameters - $expected += @( - 'Source', - 'SourceSqlCredential', - 'Destination', - 'DestinationSqlCredential', - 'ServerTrigger', - 'ExcludeServerTrigger', - 'Force', - 'EnableException', - 'Confirm', - 'WhatIf' - ) - } + BeforeAll { + $command = Get-Command Copy-DbaInstanceTrigger + $expected = $TestConfig.CommonParameters + $expected += @( + 'Source', + 'SourceSqlCredential', + 'Destination', + 'DestinationSqlCredential', + 'ServerTrigger', + 'ExcludeServerTrigger', + 'Force', + 'EnableException', + 'Confirm', + 'WhatIf' + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaLinkedServer.Tests.ps1 b/tests/Copy-DbaLinkedServer.Tests.ps1 index a0cc40e262..6745c4ddf7 100644 --- a/tests/Copy-DbaLinkedServer.Tests.ps1 +++ b/tests/Copy-DbaLinkedServer.Tests.ps1 @@ -5,26 +5,26 @@ param( ) Describe "Copy-DbaLinkedServer" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaLinkedServer - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "LinkedServer", - "ExcludeLinkedServer", - "UpgradeSqlClient", - "ExcludePassword", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaLinkedServer + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "LinkedServer", + "ExcludeLinkedServer", + "UpgradeSqlClient", + "ExcludePassword", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -112,4 +112,4 @@ Describe "Copy-DbaLinkedServer" -Tag "IntegrationTests" { $destLinked.Script() | Should -Match 'SQLNCLI11' } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaPolicyManagement.Tests.ps1 b/tests/Copy-DbaPolicyManagement.Tests.ps1 index 99043c6c15..5ede7bb692 100644 --- a/tests/Copy-DbaPolicyManagement.Tests.ps1 +++ b/tests/Copy-DbaPolicyManagement.Tests.ps1 @@ -5,26 +5,26 @@ param( ) Describe "Copy-DbaPolicyManagement" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaPolicyManagement - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Policy", - "ExcludePolicy", - "Condition", - "ExcludeCondition", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaPolicyManagement + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Policy", + "ExcludePolicy", + "Condition", + "ExcludeCondition", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -34,4 +34,4 @@ Describe "Copy-DbaPolicyManagement" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaRegServer.Tests.ps1 b/tests/Copy-DbaRegServer.Tests.ps1 index 412031e6ad..40a3317f4e 100644 --- a/tests/Copy-DbaRegServer.Tests.ps1 +++ b/tests/Copy-DbaRegServer.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaRegServer" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaRegServer - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Group", - "SwitchServerName", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaRegServer + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Group", + "SwitchServerName", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaResourceGovernor.Tests.ps1 b/tests/Copy-DbaResourceGovernor.Tests.ps1 index a368cc2d3c..923d6dc20b 100644 --- a/tests/Copy-DbaResourceGovernor.Tests.ps1 +++ b/tests/Copy-DbaResourceGovernor.Tests.ps1 @@ -91,4 +91,4 @@ Describe "Copy-DbaResourceGovernor" -Tag "IntegrationTests" { $results.Name | Should -BeExactly 'dbatoolsci_fnRG' } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaSpConfigure.Tests.ps1 b/tests/Copy-DbaSpConfigure.Tests.ps1 index f2e777d5ee..cfb9cc4789 100644 --- a/tests/Copy-DbaSpConfigure.Tests.ps1 +++ b/tests/Copy-DbaSpConfigure.Tests.ps1 @@ -5,23 +5,23 @@ param( ) Describe "Copy-DbaSpConfigure" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaSpConfigure - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "ConfigName", - "ExcludeConfigName", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaSpConfigure + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "ConfigName", + "ExcludeConfigName", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaSsisCatalog.Tests.ps1 b/tests/Copy-DbaSsisCatalog.Tests.ps1 index cfad21d21d..60fe65581e 100644 --- a/tests/Copy-DbaSsisCatalog.Tests.ps1 +++ b/tests/Copy-DbaSsisCatalog.Tests.ps1 @@ -5,27 +5,27 @@ param( ) Describe "Copy-DbaSsisCatalog" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaSsisCatalog - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "Destination", - "SourceSqlCredential", - "DestinationSqlCredential", - "Project", - "Folder", - "Environment", - "CreateCatalogPassword", - "EnableSqlClr", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaSsisCatalog + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "Destination", + "SourceSqlCredential", + "DestinationSqlCredential", + "Project", + "Folder", + "Environment", + "CreateCatalogPassword", + "EnableSqlClr", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -35,4 +35,4 @@ Describe "Copy-DbaSsisCatalog" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaStartupProcedure.Tests.ps1 b/tests/Copy-DbaStartupProcedure.Tests.ps1 index 6174c5c331..f51baa80de 100644 --- a/tests/Copy-DbaStartupProcedure.Tests.ps1 +++ b/tests/Copy-DbaStartupProcedure.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaStartupProcedure" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaStartupProcedure - $expected = $TestConfig.CommonParameters - $expected += @( - 'Source', - 'SourceSqlCredential', - 'Destination', - 'DestinationSqlCredential', - 'Procedure', - 'ExcludeProcedure', - 'Force', - 'EnableException', - 'Confirm', - 'WhatIf' - ) - } + BeforeAll { + $command = Get-Command Copy-DbaStartupProcedure + $expected = $TestConfig.CommonParameters + $expected += @( + 'Source', + 'SourceSqlCredential', + 'Destination', + 'DestinationSqlCredential', + 'Procedure', + 'ExcludeProcedure', + 'Force', + 'EnableException', + 'Confirm', + 'WhatIf' + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaSystemDbUserObject.Tests.ps1 b/tests/Copy-DbaSystemDbUserObject.Tests.ps1 index f445c12301..ac76af2ebc 100644 --- a/tests/Copy-DbaSystemDbUserObject.Tests.ps1 +++ b/tests/Copy-DbaSystemDbUserObject.Tests.ps1 @@ -5,23 +5,23 @@ param( ) Describe "Copy-DbaSystemDbUserObject" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaSystemDbUserObject - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "SourceSqlCredential", - "Destination", - "DestinationSqlCredential", - "Force", - "Classic", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaSystemDbUserObject + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "SourceSqlCredential", + "Destination", + "DestinationSqlCredential", + "Force", + "Classic", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Copy-DbaXESession.Tests.ps1 b/tests/Copy-DbaXESession.Tests.ps1 index 6c9193f3c4..334f2c2399 100644 --- a/tests/Copy-DbaXESession.Tests.ps1 +++ b/tests/Copy-DbaXESession.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Copy-DbaXESession" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaXESession - $expected = $TestConfig.CommonParameters - $expected += @( - "Source", - "Destination", - "SourceSqlCredential", - "DestinationSqlCredential", - "XeSession", - "ExcludeXeSession", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaXESession + $expected = $TestConfig.CommonParameters + $expected += @( + "Source", + "Destination", + "SourceSqlCredential", + "DestinationSqlCredential", + "XeSession", + "ExcludeXeSession", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -32,4 +32,4 @@ Describe "Copy-DbaXESession" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Copy-DbaXESessionTemplate.Tests.ps1 b/tests/Copy-DbaXESessionTemplate.Tests.ps1 index c5a416e9e5..c1499ba27e 100644 --- a/tests/Copy-DbaXESessionTemplate.Tests.ps1 +++ b/tests/Copy-DbaXESessionTemplate.Tests.ps1 @@ -5,17 +5,17 @@ param( ) Describe "Copy-DbaXESessionTemplate" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Copy-DbaXESessionTemplate - $expected = $TestConfig.CommonParameters - $expected += @( - "Path", - "Destination", - "EnableException" - ) - } + BeforeAll { + $command = Get-Command Copy-DbaXESessionTemplate + $expected = $TestConfig.CommonParameters + $expected += @( + "Path", + "Destination", + "EnableException" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -35,4 +35,4 @@ Describe "Copy-DbaXESessionTemplate" -Tag "IntegrationTests" { Get-ChildItem "$home\Documents\SQL Server Management Studio\Templates\XEventTemplates" | Where-Object Name -eq $source | Should -Not -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Disable-DbaAgHadr.Tests.ps1 b/tests/Disable-DbaAgHadr.Tests.ps1 index 1a35a28cdf..d0a9bffb74 100644 --- a/tests/Disable-DbaAgHadr.Tests.ps1 +++ b/tests/Disable-DbaAgHadr.Tests.ps1 @@ -5,20 +5,20 @@ param( ) Describe "Disable-DbaAgHadr" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disable-DbaAgHadr - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "Credential", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Disable-DbaAgHadr + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "Credential", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Disable-DbaDbEncryption.Tests.ps1 b/tests/Disable-DbaDbEncryption.Tests.ps1 index fb3e00c1c2..8fca2d5c83 100644 --- a/tests/Disable-DbaDbEncryption.Tests.ps1 +++ b/tests/Disable-DbaDbEncryption.Tests.ps1 @@ -5,20 +5,20 @@ param( ) Describe "Disable-DbaDbEncryption" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disable-DbaDbEncryption - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "Database", - "InputObject", - "NoEncryptionKeyDrop", - "EnableException" - ) - } + BeforeAll { + $command = Get-Command Disable-DbaDbEncryption + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "Database", + "InputObject", + "NoEncryptionKeyDrop", + "EnableException" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Disable-DbaForceNetworkEncryption.Tests.ps1 b/tests/Disable-DbaForceNetworkEncryption.Tests.ps1 index 3ab13c0a2b..abbdb98a02 100644 --- a/tests/Disable-DbaForceNetworkEncryption.Tests.ps1 +++ b/tests/Disable-DbaForceNetworkEncryption.Tests.ps1 @@ -5,19 +5,19 @@ param( ) Describe "Disable-DbaForceNetworkEncryption" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disable-DbaForceNetworkEncryption - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "Credential", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Disable-DbaForceNetworkEncryption + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "Credential", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Disable-DbaHideInstance.Tests.ps1 b/tests/Disable-DbaHideInstance.Tests.ps1 index 6f9c7271ef..91550a48eb 100644 --- a/tests/Disable-DbaHideInstance.Tests.ps1 +++ b/tests/Disable-DbaHideInstance.Tests.ps1 @@ -5,19 +5,19 @@ param( ) Describe "Disable-DbaHideInstance" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disable-DbaHideInstance - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "Credential", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Disable-DbaHideInstance + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "Credential", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Disable-DbaReplPublishing.Tests.ps1 b/tests/Disable-DbaReplPublishing.Tests.ps1 index 5f069bc240..7b63602781 100644 --- a/tests/Disable-DbaReplPublishing.Tests.ps1 +++ b/tests/Disable-DbaReplPublishing.Tests.ps1 @@ -7,20 +7,20 @@ param( Add-ReplicationLibrary Describe "Disable-DbaReplPublishing" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disable-DbaReplPublishing - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Disable-DbaReplPublishing + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Disable-DbaStartupProcedure.Tests.ps1 b/tests/Disable-DbaStartupProcedure.Tests.ps1 index dfaa7e991a..cb62f4e3ec 100644 --- a/tests/Disable-DbaStartupProcedure.Tests.ps1 +++ b/tests/Disable-DbaStartupProcedure.Tests.ps1 @@ -5,21 +5,21 @@ param( ) Describe "Disable-DbaStartupProcedure" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disable-DbaStartupProcedure - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "StartupProcedure", - "InputObject", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Disable-DbaStartupProcedure + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "StartupProcedure", + "InputObject", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Disable-DbaTraceFlag.Tests.ps1 b/tests/Disable-DbaTraceFlag.Tests.ps1 index 51f3201927..3954f17521 100644 --- a/tests/Disable-DbaTraceFlag.Tests.ps1 +++ b/tests/Disable-DbaTraceFlag.Tests.ps1 @@ -5,18 +5,18 @@ param( ) Describe "Disable-DbaTraceFlag" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disable-DbaTraceFlag - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "TraceFlag", - "EnableException" - ) - } + BeforeAll { + $command = Get-Command Disable-DbaTraceFlag + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "TraceFlag", + "EnableException" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Disconnect-DbaInstance.Tests.ps1 b/tests/Disconnect-DbaInstance.Tests.ps1 index 08c9c3f903..5816f38aaa 100644 --- a/tests/Disconnect-DbaInstance.Tests.ps1 +++ b/tests/Disconnect-DbaInstance.Tests.ps1 @@ -5,18 +5,18 @@ param( ) Describe "Disconnect-DbaInstance" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Disconnect-DbaInstance - $expected = $TestConfig.CommonParameters - $expected += @( - "InputObject", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Disconnect-DbaInstance + $expected = $TestConfig.CommonParameters + $expected += @( + "InputObject", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Enable-DbaAgHadr.Tests.ps1 b/tests/Enable-DbaAgHadr.Tests.ps1 index 03750a9883..6b892bc729 100644 --- a/tests/Enable-DbaAgHadr.Tests.ps1 +++ b/tests/Enable-DbaAgHadr.Tests.ps1 @@ -5,20 +5,20 @@ param( ) Describe "Enable-DbaAgHadr" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaAgHadr - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "Credential", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaAgHadr + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "Credential", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Enable-DbaDbEncryption.Tests.ps1 b/tests/Enable-DbaDbEncryption.Tests.ps1 index b4ccfd1a46..927afd7b9f 100644 --- a/tests/Enable-DbaDbEncryption.Tests.ps1 +++ b/tests/Enable-DbaDbEncryption.Tests.ps1 @@ -5,23 +5,23 @@ param( ) Describe "Enable-DbaDbEncryption" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaDbEncryption - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "Database", - "EncryptorName", - "InputObject", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaDbEncryption + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "Database", + "EncryptorName", + "InputObject", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Enable-DbaFilestream.Tests.ps1 b/tests/Enable-DbaFilestream.Tests.ps1 index 10ecb5574a..944ff6c940 100644 --- a/tests/Enable-DbaFilestream.Tests.ps1 +++ b/tests/Enable-DbaFilestream.Tests.ps1 @@ -5,23 +5,23 @@ param( ) Describe "Enable-DbaFilestream" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaFilestream - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "Credential", - "FileStreamLevel", - "ShareName", - "Force", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaFilestream + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "Credential", + "FileStreamLevel", + "ShareName", + "Force", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Enable-DbaForceNetworkEncryption.Tests.ps1 b/tests/Enable-DbaForceNetworkEncryption.Tests.ps1 index a67b8dd32c..0147133461 100644 --- a/tests/Enable-DbaForceNetworkEncryption.Tests.ps1 +++ b/tests/Enable-DbaForceNetworkEncryption.Tests.ps1 @@ -5,19 +5,19 @@ param( ) Describe "Enable-DbaForceNetworkEncryption" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaForceNetworkEncryption - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "Credential", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaForceNetworkEncryption + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "Credential", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Enable-DbaHideInstance.Tests.ps1 b/tests/Enable-DbaHideInstance.Tests.ps1 index d5f9bac77a..a2b4885226 100644 --- a/tests/Enable-DbaHideInstance.Tests.ps1 +++ b/tests/Enable-DbaHideInstance.Tests.ps1 @@ -5,19 +5,19 @@ param( ) Describe "Enable-DbaHideInstance" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaHideInstance - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "Credential", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaHideInstance + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "Credential", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Enable-DbaReplDistributor.Tests.ps1 b/tests/Enable-DbaReplDistributor.Tests.ps1 index e9de66c058..c86a5fca21 100644 --- a/tests/Enable-DbaReplDistributor.Tests.ps1 +++ b/tests/Enable-DbaReplDistributor.Tests.ps1 @@ -7,20 +7,20 @@ param( Add-ReplicationLibrary Describe "Enable-DbaReplDistributor" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaReplDistributor - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "DistributionDatabase", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaReplDistributor + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "DistributionDatabase", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -30,4 +30,4 @@ Describe "Enable-DbaReplDistributor" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Enable-DbaReplPublishing.Tests.ps1 b/tests/Enable-DbaReplPublishing.Tests.ps1 index ab45b3a37e..b72e9a2724 100644 --- a/tests/Enable-DbaReplPublishing.Tests.ps1 +++ b/tests/Enable-DbaReplPublishing.Tests.ps1 @@ -7,21 +7,21 @@ param( Add-ReplicationLibrary Describe "Enable-DbaReplPublishing" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaReplPublishing - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "SnapshotShare", - "PublisherSqlLogin", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaReplPublishing + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "SnapshotShare", + "PublisherSqlLogin", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } @@ -31,4 +31,4 @@ Describe "Enable-DbaReplPublishing" -Tag "UnitTests" { Compare-Object -ReferenceObject $expected -DifferenceObject $hasparms | Should -BeNullOrEmpty } } -} \ No newline at end of file +} diff --git a/tests/Enable-DbaStartupProcedure.Tests.ps1 b/tests/Enable-DbaStartupProcedure.Tests.ps1 index 28db6e14ae..a141eccc29 100644 --- a/tests/Enable-DbaStartupProcedure.Tests.ps1 +++ b/tests/Enable-DbaStartupProcedure.Tests.ps1 @@ -5,20 +5,20 @@ param( ) Describe "Enable-DbaStartupProcedure" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaStartupProcedure - $expected = ($TestConfig = Get-TestConfig).CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "StartupProcedure", - "EnableException", - "WhatIf", - "Confirm" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaStartupProcedure + $expected = ($TestConfig = Get-TestConfig).CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "StartupProcedure", + "EnableException", + "WhatIf", + "Confirm" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Enable-DbaTraceFlag.Tests.ps1 b/tests/Enable-DbaTraceFlag.Tests.ps1 index 07e95d32e7..19ea7ed5e1 100644 --- a/tests/Enable-DbaTraceFlag.Tests.ps1 +++ b/tests/Enable-DbaTraceFlag.Tests.ps1 @@ -5,18 +5,18 @@ param( ) Describe "Enable-DbaTraceFlag" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Enable-DbaTraceFlag - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "TraceFlag", - "EnableException" - ) - } + BeforeAll { + $command = Get-Command Enable-DbaTraceFlag + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "TraceFlag", + "EnableException" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Expand-DbaDbLogFile.Tests.ps1 b/tests/Expand-DbaDbLogFile.Tests.ps1 index 0f31ceae1b..65d57ace15 100644 --- a/tests/Expand-DbaDbLogFile.Tests.ps1 +++ b/tests/Expand-DbaDbLogFile.Tests.ps1 @@ -5,28 +5,28 @@ param( ) Describe "Expand-DbaDbLogFile" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Expand-DbaDbLogFile - $expected = $TestConfig.CommonParameters - $expected += @( - 'SqlInstance', - 'SqlCredential', - 'Database', - 'ExcludeDatabase', - 'TargetLogSize', - 'IncrementSize', - 'LogFileId', - 'ShrinkLogFile', - 'ShrinkSize', - 'BackupDirectory', - 'ExcludeDiskSpaceValidation', - 'EnableException', - 'Confirm', - 'WhatIf' - ) - } + BeforeAll { + $command = Get-Command Expand-DbaDbLogFile + $expected = $TestConfig.CommonParameters + $expected += @( + 'SqlInstance', + 'SqlCredential', + 'Database', + 'ExcludeDatabase', + 'TargetLogSize', + 'IncrementSize', + 'LogFileId', + 'ShrinkLogFile', + 'ShrinkSize', + 'BackupDirectory', + 'ExcludeDiskSpaceValidation', + 'EnableException', + 'Confirm', + 'WhatIf' + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Export-DbaBinaryFile.Tests.ps1 b/tests/Export-DbaBinaryFile.Tests.ps1 index f7e64e201e..a734aa8814 100644 --- a/tests/Export-DbaBinaryFile.Tests.ps1 +++ b/tests/Export-DbaBinaryFile.Tests.ps1 @@ -5,28 +5,28 @@ param( ) Describe "Export-DbaBinaryFile" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Export-DbaBinaryFile - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "SqlCredential", - "Database", - "Table", - "Schema", - "FileNameColumn", - "BinaryColumn", - "Path", - "FilePath", - "Query", - "InputObject", - "EnableException", - "Confirm", - "WhatIf" - ) - } + BeforeAll { + $command = Get-Command Export-DbaBinaryFile + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "SqlCredential", + "Database", + "Table", + "Schema", + "FileNameColumn", + "BinaryColumn", + "Path", + "FilePath", + "Query", + "InputObject", + "EnableException", + "Confirm", + "WhatIf" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem } diff --git a/tests/Export-DbaCredential.Tests.ps1 b/tests/Export-DbaCredential.Tests.ps1 index 0283bf8f00..7b97d43bd4 100644 --- a/tests/Export-DbaCredential.Tests.ps1 +++ b/tests/Export-DbaCredential.Tests.ps1 @@ -5,24 +5,24 @@ param( ) Describe "Export-DbaCredential" -Tag "UnitTests" { - Context "Parameter validation" { - BeforeAll { - $command = Get-Command Export-DbaCredential - $expected = $TestConfig.CommonParameters - $expected += @( - "SqlInstance", - "Identity", - "SqlCredential", - "Credential", - "Path", - "FilePath", - "ExcludePassword", - "Append", - "InputObject", - "EnableException" - ) - } + BeforeAll { + $command = Get-Command Export-DbaCredential + $expected = $TestConfig.CommonParameters + $expected += @( + "SqlInstance", + "Identity", + "SqlCredential", + "Credential", + "Path", + "FilePath", + "ExcludePassword", + "Append", + "InputObject", + "EnableException" + ) + } + Context "Parameter validation" { It "Has parameter: <_>" -ForEach $expected { $command | Should -HaveParameter $PSItem }