🧪 Add tests for -n newline toggle option
This commit is contained in:
parent
7c2af88233
commit
94110cda3e
|
@ -63,3 +63,15 @@ typing result"
|
|||
BEMOJI_DEFAULT_CMD="echo my custom command" BEMOJI_CLIP_CMD="echo my clipping" run bemoji -c 3>&-
|
||||
assert_output "my clipping"
|
||||
}
|
||||
|
||||
@test "Prints output with newline by default" {
|
||||
bats_require_minimum_version 1.5.0
|
||||
BEMOJI_PICKER_CMD="echo heart" run --keep-empty-lines -- bemoji -e
|
||||
assert_output --regexp '^heart\n$'
|
||||
}
|
||||
|
||||
@test "Prints output without newline on -n option" {
|
||||
bats_require_minimum_version 1.5.0
|
||||
BEMOJI_PICKER_CMD="echo heart" run --keep-empty-lines -- bemoji -ne
|
||||
assert_output --regexp '^heart$'
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue