Remove version part from imag-store tests

This commit is contained in:
Matthias Beyer 2016-09-05 00:36:45 +02:00
parent 70a17ca62c
commit 24c73325f3
3 changed files with 17 additions and 17 deletions

View file

@ -4,7 +4,7 @@ source $(dirname ${BASH_SOURCE[0]})/../../tests/utils.sh
source $(dirname ${BASH_SOURCE[0]})/utils.sh
test_call() {
imag-store create -p test-call~0.2.0
imag-store create -p test-call
if [[ ! $? -eq 0 ]]; then
err "Return value should be zero, was non-zero"
return 1;
@ -12,7 +12,7 @@ test_call() {
}
test_call_id() {
imag-store create -i test-call~0.2.0
imag-store create -i test-call
if [[ ! $? -eq 0 ]]; then
err "Return value should be zero, was non-zero"
return 1;
@ -28,7 +28,7 @@ test_call_no_id() {
}
test_mkstore() {
imag-store create -p test-mkstore~0.2.0 || { err "Calling imag failed"; return 1; }
imag-store create -p test-mkstore || { err "Calling imag failed"; return 1; }
if [[ -d ${STORE} ]]; then
out "Store exists."
else
@ -48,12 +48,12 @@ version = "0.2.0"
EOS
)
imag-store create -p test-std-header~0.2.0
local result=$(cat ${STORE}/test-std-header~0.2.0)
imag-store create -p test-std-header
local result=$(cat ${STORE}/test-std-header)
if [[ "$expected" == "$result" ]]; then
out "Expected store entry == result"
else
err "${STORE}/test-std-header~0.2.0 differs from expected"
err "${STORE}/test-std-header differs from expected"
return 1
fi
}
@ -72,8 +72,8 @@ zzz = "z"
EOS
)
imag-store create -p test-std-header-plus-custom~0.2.0 entry -h zzz.zzz=z
local result=$(cat ${STORE}/test-std-header-plus-custom~0.2.0)
imag-store create -p test-std-header-plus-custom entry -h zzz.zzz=z
local result=$(cat ${STORE}/test-std-header-plus-custom)
if [[ "$expected" == "$result" ]]; then
out "Expected store entry == result"
else
@ -99,7 +99,7 @@ zzz = "z"
EOS
)
local filename="test-std-header-plus-custom-multiheader~0.2.0"
local filename="test-std-header-plus-custom-multiheader"
imag-store create -p $filename entry -h zzz.zzz=z foo.bar=baz
local result=$(cat ${STORE}/$filename)
if [[ "$expected" == "$result" ]]; then
@ -126,7 +126,7 @@ zzz = "z"
EOS
)
local filename="test-std-header-plus-custom-mutliheader-same-section~0.2.0"
local filename="test-std-header-plus-custom-mutliheader-same-section"
imag-store create -p $filename entry -h zzz.zzz=z zzz.bar=baz
local result=$(cat ${STORE}/$filename)
if [[ "$expected" == "$result" ]]; then
@ -151,7 +151,7 @@ content
EOS
)
local name="test-std-header-plus-custom-and-content~0.2.0"
local name="test-std-header-plus-custom-and-content"
imag-store create -p $name entry -h zzz.zzz=z -c content
local result=$(cat ${STORE}/$name)
if [[ "$expected" == "$result" ]]; then

View file

@ -18,7 +18,7 @@ retrieve() {
}
test_retrieve_nothing() {
local id="test-retrieve_nothing~0.2.0"
local id="test-retrieve_nothing"
imag-store create -p ${id} || { err "create failed"; return 1; }
@ -33,7 +33,7 @@ test_retrieve_nothing() {
}
test_retrieve_content() {
local id="test-retrieve_simple~0.2.0"
local id="test-retrieve_simple"
imag-store create -p ${id} || { err "create failed"; return 1; }
@ -49,12 +49,12 @@ test_retrieve_content() {
}
test_retrieve_header() {
local id="test-retrieve_simple~0.2.0"
local id="test-retrieve_simple"
imag-store create -p ${id} || { err "create failed"; return 1; }
out "Going to test the retrieve functionality now"
local header_out="$(retrieve --id /${id} --header)"
local header_out="$(retrieve --id ${id} --header)"
out "Retrieving for header_out finished"
if [[ ! "$header_out" != "$(std_header)" ]]; then
@ -64,7 +64,7 @@ test_retrieve_header() {
}
test_retrieve_raw() {
local id="test-retrieve_simple~0.2.0"
local id="test-retrieve_simple"
imag-store create -p ${id} || { err "create failed"; return 1; }

View file

@ -12,7 +12,7 @@ delete() {
}
test_delete_simple() {
local name="test~0.2.0"
local name="test"
create -p $name
delete --id $name