Resource fails with fatal error if the computer already is in the domain.
The test should pick this up, which now it doesn't and hence throws a fatal exception when attempting to join the domain again.
Error:
Cannot add computer 'x' to domain 'y' because it is already in that domain.
+ CategoryInfo : InvalidOperation: (x:) [], CimException
+ FullyQualifiedErrorId : AddComputerToSameDomain,Microsoft.PowerShell.Commands.AddComputerCommand
+ PSComputerName : localhost
Resource fails with fatal error if the computer already is in the domain.
The test should pick this up, which now it doesn't and hence throws a fatal exception when attempting to join the domain again.
Error:
Cannot add computer 'x' to domain 'y' because it is already in that domain.
+ CategoryInfo : InvalidOperation: (x:) [], CimException
+ FullyQualifiedErrorId : AddComputerToSameDomain,Microsoft.PowerShell.Commands.AddComputerCommand
+ PSComputerName : localhost