Tests/Public/Support/Helper/Format-StringRemoveSpecialCharacter.Tests.ps1
# Module: TeamsFunctions # Function: Test # Author: David Eberhardt # Updated: 11-OCT-2020 InModuleScope TeamsFunctions { BeforeAll { # } Describe -Tags ('Unit', 'Acceptance') "Function 'Format-StringRemoveSpecialCharacter'" { It 'Should be of type System.String' { Format-StringRemoveSpecialCharacter -String 'Test' | Should -BeOfType System.String } It 'Should return correct String manipulations' { Format-StringRemoveSpecialCharacter -String 'Test' | Should -BeExactly 'Test' Format-StringRemoveSpecialCharacter -String 'wow#@!`~)(\|?/}{-_=+*' | Should -BeExactly 'wow' Format-StringRemoveSpecialCharacter -String 'wow#@!`~)(\|?/}{-_=+*' -SpecialCharacterToKeep '*', '_', '-' | Should -BeExactly 'wow-_*' } } } |