Merge pull request #18625 from bluca/sysext_refactor

dissect: parse and store extension-release metadata
This commit is contained in:
Luca Boccassi
2021-02-18 10:43:08 +00:00
committed by GitHub
11 changed files with 324 additions and 117 deletions
+12
View File
@@ -44,6 +44,17 @@ static void test_strv_env_get(void) {
assert_se(streq(strv_env_get(l, "FOUR"), "4"));
}
static void test_strv_env_pairs_get(void) {
log_info("/* %s */", __func__);
char **l = STRV_MAKE("ONE_OR_TWO", "1", "THREE", "3", "ONE_OR_TWO", "2", "FOUR", "4", "FIVE", "5", "SIX", "FIVE", "SEVEN", "7");
assert_se(streq(strv_env_pairs_get(l, "ONE_OR_TWO"), "2"));
assert_se(streq(strv_env_pairs_get(l, "THREE"), "3"));
assert_se(streq(strv_env_pairs_get(l, "FOUR"), "4"));
assert_se(streq(strv_env_pairs_get(l, "FIVE"), "5"));
}
static void test_strv_env_unset(void) {
log_info("/* %s */", __func__);
@@ -390,6 +401,7 @@ int main(int argc, char *argv[]) {
test_strv_env_delete();
test_strv_env_get();
test_strv_env_pairs_get();
test_strv_env_unset();
test_strv_env_merge();
test_strv_env_replace_strdup();