aboutsummaryrefslogtreecommitdiff
path: root/tests/load/driver.cxx
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2020-09-09 15:58:01 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2020-09-09 15:59:29 +0300
commit1a4a071568116f1131507f692f5618d5e5748b71 (patch)
tree483fac35b7616980ad3b2d027b4701b2d05f4330 /tests/load/driver.cxx
parenteb4f581b6a544a6535f771bcb7017bceca2530fc (diff)
Fix loader assertion failure for external repository without local cache
Now loader fetches external repositories into temporary local caches.
Diffstat (limited to 'tests/load/driver.cxx')
-rw-r--r--tests/load/driver.cxx16
1 files changed, 7 insertions, 9 deletions
diff --git a/tests/load/driver.cxx b/tests/load/driver.cxx
index b4c43cc..8192827 100644
--- a/tests/load/driver.cxx
+++ b/tests/load/driver.cxx
@@ -975,8 +975,8 @@ test_pkg_repos (const cstrings& loader_args,
assert (tr->location.canonical_name () == "pkg:dev.cppget.org/testing");
assert (tr->location.string () ==
"http://dev.cppget.org/1/testing");
- assert (tr->display_name.empty ());
- assert (tr->priority == 0);
+ assert (tr->display_name == "testing");
+ assert (tr->priority == 3);
assert (tr->interface_url &&
*tr->interface_url == "http://test.cppget.org/hello/");
assert (!tr->email);
@@ -994,7 +994,7 @@ test_pkg_repos (const cstrings& loader_args,
assert (tr->repositories_timestamp ==
file_mtime (tr->cache_location.path () / repositories));
- assert (!tr->internal);
+ assert (tr->internal);
assert (tr->prerequisites.empty ());
assert (tr->complements.size () == 1);
assert (tr->complements[0].load () == gr);
@@ -1007,9 +1007,8 @@ test_pkg_repos (const cstrings& loader_args,
db.load<package> (
package_id (tenant, package_name ("libmisc"), version ("2.4.0"))));
- assert (check_external (*mpv0));
- assert (mpv0->other_repositories.size () == 1);
- assert (mpv0->other_repositories[0].load () == tr);
+ assert (mpv0->internal_repository.load () == tr);
+ assert (mpv0->other_repositories.empty ());
assert (check_location (mpv0));
assert (!mpv0->buildable);
@@ -1019,9 +1018,8 @@ test_pkg_repos (const cstrings& loader_args,
db.load<package> (
package_id (tenant, package_name ("libmisc"), version ("2.3.0+1"))));
- assert (check_external (*mpv1));
- assert (mpv1->other_repositories.size () == 1);
- assert (mpv1->other_repositories[0].load () == tr);
+ assert (mpv1->internal_repository.load () == tr);
+ assert (mpv1->other_repositories.empty ());
assert (check_location (mpv1));
assert (!mpv1->buildable);