mirror of
https://github.com/asdf-vm/asdf.git
synced 2024-11-15 01:28:17 -07:00
Add primitive tests for plugin_test_command.
This commit is contained in:
parent
bebdd04084
commit
60e67c4f5b
27
test/plugin_test_command.bats
Normal file
27
test/plugin_test_command.bats
Normal file
@ -0,0 +1,27 @@
|
||||
#!/usr/bin/env bats
|
||||
|
||||
load test_helpers
|
||||
|
||||
. $(dirname $BATS_TEST_DIRNAME)/lib/commands/plugin-add.sh
|
||||
. $(dirname $BATS_TEST_DIRNAME)/lib/commands/plugin-list.sh
|
||||
. $(dirname $BATS_TEST_DIRNAME)/lib/commands/plugin-test.sh
|
||||
|
||||
setup() {
|
||||
setup_asdf_dir
|
||||
}
|
||||
|
||||
teardown() {
|
||||
clean_asdf_dir
|
||||
}
|
||||
|
||||
@test "plugin_test_command with no URL specified prints an error" {
|
||||
run plugin_test_command "elixir"
|
||||
[ "$status" -eq 1 ]
|
||||
[ "$output" = "FAILED: please provide a plugin name and url" ]
|
||||
}
|
||||
|
||||
@test "plugin_test_command with no name or URL specified prints an error" {
|
||||
run plugin_test_command
|
||||
[ "$status" -eq 1 ]
|
||||
[ "$output" = "FAILED: please provide a plugin name and url" ]
|
||||
}
|
Loading…
Reference in New Issue
Block a user