Skip to content

Commit

Permalink
Merge pull request #42 from AsrOneSdk/sanjkuma-dev
Browse files Browse the repository at this point in the history
Use WriteWarning instead of WriteDebug.
  • Loading branch information
NehaRaje committed Feb 9, 2015
2 parents 702c98d + 498d7e7 commit 8bb31e3
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -72,15 +72,15 @@ function Test-E2E_DeleteAndDissociate
{
if ($association.AssociationStatus -eq "Paired")
{
// We have got the paired profile. Fire delete and dissociate
# We have got the paired profile. Fire delete and dissociate
$pcPri = Get-AzureSiteRecoveryProtectionContainer -Id $association.PrimaryProtectionContainerId
$pcRec = Get-AzureSiteRecoveryProtectionContainer -Id $association.RecoveryProtectionContainerId
$job = Start-AzureSiteRecoveryProtectionProfileDissociationJob -PrimaryProtectionContainer $pcPri -RecoveryProtectionContainer $pcRec -ProtectionProfile $profile

# Validate_ProfileDissociation_JobSucceeded
if ($Validate_ProfileDissociation_JobSucceeded -eq $true)
{
WaitForJobCompletion -JobId $job.ID
WaitForJobCompletion -JobId $job.ID -NumOfSecondsToWait 600
$job = Get-AzureSiteRecoveryJob -Id $job.ID
Assert-True { $job.State -eq "Succeeded" }
}
Expand Down Expand Up @@ -134,7 +134,7 @@ function Test-E2E_CreateAndAssociate
# Validate_ProfileAssociation_JobSucceeded
if ($Validate_ProfileAssociation_JobSucceeded -eq $true)
{
WaitForJobCompletion -JobId $job.ID
WaitForJobCompletion -JobId $job.ID -NumOfSecondsToWait 600
$job = Get-AzureSiteRecoveryJob -Id $job.ID
Assert-True { $job.State -eq "Succeeded" }
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,10 @@ protected void ValidateUsageById(string replicationProvider, string paramName)
}
else
{
this.WriteDebugWithTimestamp(
this.WriteWarningWithTimestamp(
string.Format(
Properties.Resources.IDBasedParamUsageNotSupportedFromNextRelease,
paramName);
paramName));
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,9 +187,10 @@ public override void ExecuteCmdlet()
}
else
{
this.WriteDebugWithTimestamp(
this.WriteWarningWithTimestamp(
string.Format(
Properties.Resources.MandatoryParamFromNextRelease,
"ProtectionProfile");
"ProtectionProfile"));
string pcId = this.ProtectionContainerId ?? this.ProtectionEntity.ProtectionContainerId;
var pc = RecoveryServicesClient.GetAzureSiteRecoveryProtectionContainer(
pcId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,10 @@ public override void ExecuteCmdlet()
{
if (string.IsNullOrEmpty(this.Direction))
{
this.WriteDebugWithTimestamp(
Properties.Resources.MandatoryParamFromNextRelease,
Constants.Direction);
this.WriteWarningWithTimestamp(
string.Format(
Properties.Resources.MandatoryParamFromNextRelease,
Constants.Direction));
}

switch (this.ParameterSetName)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -156,16 +156,18 @@ public override void ExecuteCmdlet()
{
if (this.NetworkType == null)
{
this.WriteDebugWithTimestamp(
Properties.Resources.MandatoryParamFromNextRelease,
Constants.NetworkType);
this.WriteWarningWithTimestamp(
string.Format(
Properties.Resources.MandatoryParamFromNextRelease,
Constants.NetworkType));
}

if (this.VmNetworkId != null)
{
this.WriteDebugWithTimestamp(
Properties.Resources.IDBasedParamUsageNotSupportedFromNextRelease,
"VmNetworkId");
this.WriteWarningWithTimestamp(
string.Format(
Properties.Resources.IDBasedParamUsageNotSupportedFromNextRelease,
"VmNetworkId"));
}

if (this.NetworkType == Constants.Existing && (this.Network == null && this.VmNetworkId == null))
Expand Down

0 comments on commit 8bb31e3

Please sign in to comment.