Commit c5e71748 authored by Leo's avatar Leo

Add tests for pkgname must have uppercase

parent 3ad92d93
......@@ -252,4 +252,61 @@ assert_match() {
assert_match "${lines[0]}" "builddir.*can be removed"
}
@test 'pkgname must not have uppercase characters' {
cat <<-"EOF" >$apkbuild
pkgname=foo
EOF
run $cmd $apkbuild
[[ $status -eq 0 ]]
cat <<-"EOF" >$apkbuild
pkgname=Foo
EOF
run $cmd $apkbuild
[[ $status -eq 1 ]]
assert_match "${lines[0]}" "pkgname must not have uppercase characters"
cat <<-"EOF" >$apkbuild
pkgname=fOo
EOF
run $cmd $apkbuild
[[ $status -eq 1 ]]
assert_match "${lines[0]}" "pkgname must not have uppercase characters"
cat <<-"EOF" >$apkbuild
pkgname=fOo
EOF
run $cmd $apkbuild
[[ $status -eq 1 ]]
assert_match "${lines[0]}" "pkgname must not have uppercase characters"
cat <<-"EOF" >$apkbuild
pkgname=FOO
EOF
run $cmd $apkbuild
[[ $status -eq 1 ]]
assert_match "${lines[0]}" "pkgname must not have uppercase characters"
cat <<-"EOF" >$apkbuild
pkgname=fOO
EOF
run $cmd $apkbuild
[[ $status -eq 1 ]]
assert_match "${lines[0]}" "pkgname must not have uppercase characters"
cat <<-"EOF" >$apkbuild
pkgname=FoO
EOF
run $cmd $apkbuild
[[ $status -eq 1 ]]
assert_match "${lines[0]}" "pkgname must not have uppercase characters"
}
# vim: noexpandtab
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment