mirror of
https://github.com/TheLocehiliosan/yadm
synced 2024-10-27 20:34:27 +00:00
Switch to semantic versioning
This commit is contained in:
parent
9d21376f88
commit
79e149ed25
@ -5,7 +5,7 @@ status=;output=; #; populated by bats run()
|
|||||||
@test "Command 'version'" {
|
@test "Command 'version'" {
|
||||||
echo "
|
echo "
|
||||||
When 'version' command is provided,
|
When 'version' command is provided,
|
||||||
Print the current version with format 'yadm x.xx'
|
Print the current version with format 'yadm x.x.x'
|
||||||
Exit with 0
|
Exit with 0
|
||||||
"
|
"
|
||||||
|
|
||||||
@ -20,6 +20,6 @@ status=;output=; #; populated by bats run()
|
|||||||
#; validate status and output
|
#; validate status and output
|
||||||
[ $status -eq 0 ]
|
[ $status -eq 0 ]
|
||||||
[ "$output" = "yadm $VERSION" ]
|
[ "$output" = "yadm $VERSION" ]
|
||||||
version_regex="^yadm [[:digit:]\.]+$"
|
version_regex="^yadm [[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+$"
|
||||||
[[ "$output" =~ $version_regex ]]
|
[[ "$output" =~ $version_regex ]]
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user