2016-03-18 06:48:35 +01:00
|
|
|
Describe "NativeLinuxCommands" {
|
|
|
|
It "Should return a type of System.Object for hostname cmdlet" {
|
2016-04-08 22:36:54 +02:00
|
|
|
(hostname).GetType().BaseType | Should Be 'System.Object'
|
|
|
|
(hostname).GetType().Name | Should Be String
|
2016-03-18 06:48:35 +01:00
|
|
|
}
|
|
|
|
|
2016-04-08 22:36:54 +02:00
|
|
|
It "Should find Application grep" -Skip:$IsWindows {
|
|
|
|
(get-command grep).CommandType | Should Be Application
|
2016-03-18 08:23:57 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
It "Should pipe to grep and get result" -Skip:$IsWindows {
|
2016-04-08 22:36:54 +02:00
|
|
|
"hello world" | grep hello | Should Be "hello world"
|
2016-03-18 08:23:57 +01:00
|
|
|
}
|
2016-04-08 22:36:54 +02:00
|
|
|
|
|
|
|
It "Should find Application touch" -Skip:$IsWindows {
|
|
|
|
(get-command touch).CommandType | Should Be Application
|
2016-03-18 06:48:35 +01:00
|
|
|
}
|
|
|
|
}
|