# Tests for ob_match_arch() # # Copyright (C) 2012, 2018 Patrick McDermott # # This file is part of opkbuild. # # opkbuild is free software: you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # opkbuild is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with opkbuild. If not, see . . "${TOP_SRCDIR}/tests/aux/tap-functions.sh" . "${TOP_BUILDDIR}/lib/libopkbuild.${SHSOEXT}.${LIBOPKBUILD_SHSOVERSION}" plan_ 10 command_ok_ 'all IN [all]' -- \ ob_match_arch \ 'all' \ 'all' command_ok_ 'foo-bar-baz IN [any]' -- \ ob_match_arch \ 'foo-bar-baz' \ 'any' command_ok_ 'foo-bar-baz IN [any all]' -- \ ob_match_arch \ 'foo-bar-baz' \ 'any all' command_ok_ 'all IN [any all]' -- \ ob_match_arch \ 'all' \ 'any all' command_ok_ 'foo-bar-baz IN [foo-bar-any]' -- \ ob_match_arch \ 'foo-bar-baz' \ 'foo-bar-any' command_ok_ 'foo-bar-baz NOT IN [foo-bar-qux]' -- \ not ob_match_arch \ 'foo-bar-baz' \ 'foo-bar-qux' command_ok_ 'foo-bar-baz IN [any-qux-any any-bar-any]' -- \ ob_match_arch \ 'foo-bar-baz' \ 'any-qux-any any-bar-any' command_ok_ 'foo-bar-baz NOT IN [any-qux-any any-quux-any]' -- \ not ob_match_arch \ 'foo-bar-baz' \ 'any-qux-any any-quux-any' command_ok_ 'all NOT IN [any]' -- \ not ob_match_arch \ 'all' \ 'any' command_ok_ 'all NOT IN [foo-any-any]' -- \ not ob_match_arch \ 'all' \ 'foo-any-any'