mirror of
https://github.com/mhx/dwarfs.git
synced 2025-09-13 06:16:55 -04:00
test: don't rely on FLAC compression being available
This commit is contained in:
parent
793f87125a
commit
21901d7c2d
@ -1774,9 +1774,10 @@ TEST(mkdwarfs_test, output_file_fail_close) {
|
|||||||
EXPECT_THAT(t.err(), ::testing::HasSubstr("failed to close output file"));
|
EXPECT_THAT(t.err(), ::testing::HasSubstr("failed to close output file"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if DWARFS_HAVE_RICEPP
|
||||||
TEST(mkdwarfs_test, compression_cannot_be_used_without_category) {
|
TEST(mkdwarfs_test, compression_cannot_be_used_without_category) {
|
||||||
mkdwarfs_tester t;
|
mkdwarfs_tester t;
|
||||||
EXPECT_NE(0, t.run({"-i", "/", "-o", "-", "-C", "flac"}));
|
EXPECT_NE(0, t.run({"-i", "/", "-o", "-", "-C", "ricepp"}));
|
||||||
EXPECT_THAT(t.err(),
|
EXPECT_THAT(t.err(),
|
||||||
::testing::HasSubstr("cannot be used without a category"));
|
::testing::HasSubstr("cannot be used without a category"));
|
||||||
}
|
}
|
||||||
@ -1784,11 +1785,12 @@ TEST(mkdwarfs_test, compression_cannot_be_used_without_category) {
|
|||||||
TEST(mkdwarfs_test, compression_cannot_be_used_for_category) {
|
TEST(mkdwarfs_test, compression_cannot_be_used_for_category) {
|
||||||
mkdwarfs_tester t;
|
mkdwarfs_tester t;
|
||||||
EXPECT_NE(0, t.run({"-i", "/", "-o", "-", "--categorize", "-C",
|
EXPECT_NE(0, t.run({"-i", "/", "-o", "-", "--categorize", "-C",
|
||||||
"incompressible::flac"}));
|
"incompressible::ricepp"}));
|
||||||
EXPECT_THAT(t.err(), ::testing::HasSubstr(
|
EXPECT_THAT(t.err(), ::testing::HasSubstr(
|
||||||
"cannot be used for category 'incompressible': "
|
"cannot be used for category 'incompressible': "
|
||||||
"metadata requirements not met"));
|
"metadata requirements not met"));
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
class mkdwarfs_progress_test : public testing::TestWithParam<char const*> {};
|
class mkdwarfs_progress_test : public testing::TestWithParam<char const*> {};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user