return ret;
}
-
static R2RTest *r2r_test_new(R2RTestType type, const char *path, void *specific_test, bool load_plugins) {
R2RTest *test = R_NEW (R2RTest);
test->type = type;
free (test);
}
-R_API R2RTestDatabase * R_NONNULL r2r_test_database_new(void) {
+R_API R2RTestDatabase *R_NONNULL r2r_test_database_new(void) {
R2RTestDatabase *db = R_NEW (R2RTestDatabase);
RVecR2RTestPtr_init (&db->tests);
r_str_constpool_init (&db->strpool);
free (db);
}
+R_IPI const char *getarchos(void);
+
static R2RTestFrom test_type_for_path(const char *path) {
- R2RTestFrom res = {0};
+ R2RTestFrom res = { 0 };
res.load_plugins = false;
if (strstr (path, R_SYS_DIR "asm" R_SYS_DIR)) {
res.type = R2R_TEST_TYPE_ASM;
res.type = R2R_TEST_TYPE_CMD;
}
res.archos = false;
- if (strstr (path, R_SYS_DIR "archos") || !strcmp (path, "archos")) {
+ if ((strstr (path, R_SYS_DIR "archos" R_SYS_DIR) || !strcmp (path, "archos")) &&
+ strcmp (path + strlen (path) - strlen (getarchos ()), getarchos ())) {
res.archos = true;
}
return res;