]> gitweb.hhaalo.de Git - sane-kds-s2000w-net.git/commitdiff
change unset var teardown postinst
authorBastian Dehn <hhaalo@arcor.de>
Thu, 16 Jul 2026 17:55:06 +0000 (19:55 +0200)
committerBastian Dehn <hhaalo@arcor.de>
Thu, 16 Jul 2026 17:55:06 +0000 (19:55 +0200)
tests/postinst.bats

index 1d1352c347be0cb3e7e506aba968e18ccf62bd9f..1af18c9f4ae36efdc5847ac2af8d8560fd8779fd 100755 (executable)
@@ -9,6 +9,7 @@ setup() {
 
 teardown() {
        rm -rf ../build/dllpostinst.conf
+       unset DLLCONFIG
 }
 
 @test "ignore file does not exists" {
@@ -18,7 +19,6 @@ teardown() {
 
        assert_success
        assert_output "ERROR: ../build/dll-not-exists.conf does not exist"
-       unset DLLCONFIG
 }
 
 @test "add entry kds_s2000w_net dll.conf" {
@@ -31,7 +31,6 @@ teardown() {
        assert_line --index 1 "add kds_s2000w_net to ../build/dllpostinst.conf"
        assert_equal "$(cat ../build/dllpostinst.conf)" "kds_s2000w_net"
        assert_equal "$(cat ../build/dllpostinst.conf | wc --lines)" "1"
-       unset DLLCONFIG
 }
 
 @test "entry exists in dll.conf do nothing" {
@@ -44,5 +43,4 @@ teardown() {
        assert_output "found ../build/dllpostinst.conf"
        assert_equal "$(cat ../build/dllpostinst.conf)" "kds_s2000w_net"
        assert_equal "$(cat ../build/dllpostinst.conf | wc --lines)" "1"
-       unset DLLCONFIG
 }
\ No newline at end of file