Skip to content

Commit 6061553

Browse files
committed
test(publish): Use proper registry for workspace tests
On stabilization of `-Zpackage-workspace`, these will start passing and will need a full registry
1 parent 8a9d8bd commit 6061553

File tree

1 file changed

+5
-10
lines changed

1 file changed

+5
-10
lines changed

tests/testsuite/publish.rs

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2522,8 +2522,7 @@ You may press ctrl-c to skip waiting; the crate should be available shortly.
25222522

25232523
#[cargo_test]
25242524
fn with_duplicate_spec_in_members() {
2525-
// Use local registry for faster test times since no publish will occur
2526-
let registry = registry::init();
2525+
let registry = RegistryBuilder::new().http_api().http_index().build();
25272526

25282527
let p = project()
25292528
.file(
@@ -2630,8 +2629,7 @@ You may press ctrl-c to skip waiting; the crate should be available shortly.
26302629

26312630
#[cargo_test]
26322631
fn in_virtual_workspace() {
2633-
// Use local registry for faster test times since no publish will occur
2634-
let registry = registry::init();
2632+
let registry = RegistryBuilder::new().http_api().http_index().build();
26352633

26362634
let p = project()
26372635
.file(
@@ -2668,8 +2666,7 @@ fn in_virtual_workspace() {
26682666

26692667
#[cargo_test]
26702668
fn in_virtual_workspace_with_p() {
2671-
// `publish` generally requires a remote registry
2672-
let registry = registry::RegistryBuilder::new().http_api().build();
2669+
let registry = RegistryBuilder::new().http_api().http_index().build();
26732670

26742671
let p = project()
26752672
.file(
@@ -2771,8 +2768,7 @@ fn in_package_workspace_not_found() {
27712768

27722769
#[cargo_test]
27732770
fn in_package_workspace_found_multiple() {
2774-
// Use local registry for faster test times since no publish will occur
2775-
let registry = registry::init();
2771+
let registry = RegistryBuilder::new().http_api().http_index().build();
27762772

27772773
let p = project()
27782774
.file(
@@ -2828,8 +2824,7 @@ fn in_package_workspace_found_multiple() {
28282824
#[cargo_test]
28292825
// https://github.com/rust-lang/cargo/issues/10536
28302826
fn publish_path_dependency_without_workspace() {
2831-
// Use local registry for faster test times since no publish will occur
2832-
let registry = registry::init();
2827+
let registry = RegistryBuilder::new().http_api().http_index().build();
28332828

28342829
let p = project()
28352830
.file(

0 commit comments

Comments
 (0)