2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test basic add and list of __abbr1
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Erasing one that doesn't exist should do nothing
|
|
|
|
abbr --erase: No abbreviation named NOT_AN_ABBR
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Adding existing __abbr1 should be idempotent
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Replacing __abbr1 definition
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# __abbr1 -s and --show tests
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test erasing __abbr1
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Ensure we escape special characters on output
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Ensure we handle leading dashes in abbreviation names properly
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test that an abbr word containing spaces is rejected
|
|
|
|
abbr --add: Abbreviation 'a b c' cannot have spaces in the word
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test renaming
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test renaming a nonexistent abbreviation
|
|
|
|
abbr --rename: No abbreviation named __abbr6
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test renaming to a abbreviation with spaces
|
|
|
|
abbr --rename: Abbreviation 'g h i' cannot have spaces in the word
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test renaming without arguments
|
|
|
|
abbr --rename: Requires exactly two arguments
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test renaming with too many arguments
|
|
|
|
abbr --rename: Requires exactly two arguments
|
2017-08-04 04:25:20 +00:00
|
|
|
|
|
|
|
####################
|
2017-05-22 05:22:55 +00:00
|
|
|
# Test renaming to existing abbreviation
|
|
|
|
abbr --rename: Abbreviation __abbr12 already exists, cannot rename __abbr11
|