Skip to content

Commit

Permalink
Added workspace_default_members to more tests.
Browse files Browse the repository at this point in the history
  • Loading branch information
charles-r-earp committed May 3, 2023
1 parent e421345 commit f43e6d9
Show file tree
Hide file tree
Showing 4 changed files with 69 additions and 1 deletion.
9 changes: 9 additions & 0 deletions tests/testsuite/alt_registry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -902,6 +902,9 @@ fn alt_reg_metadata() {
"workspace_members": [
"foo 0.0.1 (path+file:[..]/foo)"
],
"workspace_default_members": [
"foo 0.0.1 (path+file:[..]/foo)"
],
"resolve": null,
"target_directory": "[..]/foo/target",
"version": 1,
Expand Down Expand Up @@ -1102,6 +1105,9 @@ fn alt_reg_metadata() {
"workspace_members": [
"foo 0.0.1 (path+file:[..]/foo)"
],
"workspace_default_members": [
"foo 0.0.1 (path+file:[..]/foo)"
],
"resolve": "{...}",
"target_directory": "[..]/foo/target",
"version": 1,
Expand Down Expand Up @@ -1265,6 +1271,9 @@ fn unknown_registry() {
"workspace_members": [
"foo 0.0.1 (path+file://[..]/foo)"
],
"workspace_default_members": [
"foo 0.0.1 (path+file://[..]/foo)"
],
"resolve": "{...}",
"target_directory": "[..]/foo/target",
"version": 1,
Expand Down
1 change: 1 addition & 0 deletions tests/testsuite/features_namespaced.rs
Original file line number Diff line number Diff line change
Expand Up @@ -609,6 +609,7 @@ fn json_exposed() {
}
],
"workspace_members": "{...}",
"workspace_default_members": "{...}",
"resolve": null,
"target_directory": "[..]foo/target",
"version": 1,
Expand Down
3 changes: 3 additions & 0 deletions tests/testsuite/git.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3337,6 +3337,9 @@ fn metadata_master_consistency() {
"workspace_members": [
"foo 0.1.0 [..]"
],
"workspace_default_members": [
"foo 0.1.0 [..]"
],
"resolve": {
"nodes": [
{
Expand Down
57 changes: 56 additions & 1 deletion tests/testsuite/metadata.rs
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ crate-type = ["lib", "staticlib"]
}
],
"workspace_members": ["foo 0.5.0 (path+file:[..]foo)"],
"workspace_default_members": ["foo 0.5.0 (path+file:[..]foo)"],
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -258,6 +259,7 @@ optional_feat = []
}
],
"workspace_members": ["foo 0.5.0 (path+file:[..]foo)"],
"workspace_default_members": ["foo 0.5.0 (path+file:[..]foo)"],
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -588,6 +590,9 @@ fn cargo_metadata_with_deps_and_version() {
"workspace_members": [
"foo 0.5.0 (path+file:[..]foo)"
],
"workspace_default_members": [
"foo 0.5.0 (path+file:[..]foo)"
],
"workspace_root": "[..]/foo",
"metadata": null
}"#,
Expand Down Expand Up @@ -669,6 +674,9 @@ name = "ex"
"workspace_members": [
"foo 0.1.0 (path+file:[..]foo)"
],
"workspace_default_members": [
"foo 0.1.0 (path+file:[..]foo)"
],
"resolve": {
"root": "foo 0.1.0 (path+file://[..]foo)",
"nodes": [
Expand Down Expand Up @@ -763,6 +771,9 @@ crate-type = ["rlib", "dylib"]
],
"workspace_members": [
"foo 0.1.0 (path+file:[..]foo)"
],
"workspace_default_members": [
"foo 0.1.0 (path+file:[..]foo)"
],
"resolve": {
"root": "foo 0.1.0 (path+file://[..]foo)",
Expand Down Expand Up @@ -893,6 +904,7 @@ fn workspace_metadata() {
}
],
"workspace_members": ["bar 0.5.0 (path+file:[..]bar)", "baz 0.5.0 (path+file:[..]baz)"],
"workspace_default_members": ["bar 0.5.0 (path+file:[..]bar)", "baz 0.5.0 (path+file:[..]baz)"],
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -1124,6 +1136,11 @@ fn workspace_metadata_with_dependencies_no_deps() {
"artifact 0.5.0 (path+file:[..]/foo/artifact)",
"baz 0.5.0 (path+file:[..]baz)"
],
"workspace_default_members": [
"bar 0.5.0 (path+file:[..]bar)",
"artifact 0.5.0 (path+file:[..]/foo/artifact)",
"baz 0.5.0 (path+file:[..]baz)"
],
"resolve": null,
"target_directory": "[..]foo/target",
"version": 1,
Expand Down Expand Up @@ -1756,6 +1773,12 @@ fn workspace_metadata_with_dependencies_and_resolve() {
"bin-only-artifact 0.5.0 (path+file://[..]/foo/bin-only-artifact)",
"non-artifact 0.5.0 (path+file://[..]/foo/non-artifact)"
],
"workspace_default_members": [
"bar 0.5.0 (path+file://[..]/foo/bar)",
"artifact 0.5.0 (path+file://[..]/foo/artifact)",
"bin-only-artifact 0.5.0 (path+file://[..]/foo/bin-only-artifact)",
"non-artifact 0.5.0 (path+file://[..]/foo/non-artifact)"
],
"workspace_root": "[..]/foo"
}
"#,
Expand Down Expand Up @@ -2149,6 +2172,7 @@ fn package_metadata() {
}
],
"workspace_members": ["foo[..]"],
"workspace_default_members": ["foo[..]"],
"resolve": null,
"target_directory": "[..]foo/target",
"version": 1,
Expand Down Expand Up @@ -2224,6 +2248,7 @@ fn package_publish() {
}
],
"workspace_members": ["foo[..]"],
"workspace_default_members": ["foo[..]"],
"resolve": null,
"target_directory": "[..]foo/target",
"version": 1,
Expand Down Expand Up @@ -2319,7 +2344,9 @@ fn cargo_metadata_path_to_cargo_toml_project() {
"workspace_members": [
"bar 0.5.0 (path+file:[..])"
],
"workspace_default_members": [],
"workspace_default_members": [
"bar 0.5.0 (path+file:[..])"
],
"workspace_root": "[..]",
"metadata": null
}
Expand Down Expand Up @@ -2408,6 +2435,9 @@ fn package_edition_2018() {
"workspace_members": [
"foo 0.1.0 (path+file:[..])"
],
"workspace_default_members": [
"foo 0.1.0 (path+file:[..])"
],
"workspace_root": "[..]",
"metadata": null
}
Expand Down Expand Up @@ -2556,6 +2586,9 @@ fn target_edition_2018() {
"workspace_members": [
"foo 0.1.0 (path+file:[..])"
],
"workspace_default_members": [
"foo 0.1.0 (path+file:[..])"
],
"workspace_root": "[..]",
"metadata": null
}
Expand Down Expand Up @@ -2792,6 +2825,9 @@ fn rename_dependency() {
"workspace_members": [
"foo 0.0.1[..]"
],
"workspace_default_members": [
"foo 0.0.1[..]"
],
"workspace_root": "[..]",
"metadata": null
}"#,
Expand Down Expand Up @@ -2892,6 +2928,9 @@ fn metadata_links() {
"workspace_members": [
"foo 0.5.0 [..]"
],
"workspace_default_members": [
"foo 0.5.0 [..]"
],
"workspace_root": "[..]/foo",
"metadata": null
}
Expand Down Expand Up @@ -2982,6 +3021,9 @@ fn deps_with_bin_only() {
"workspace_members": [
"foo 0.1.0 ([..])"
],
"workspace_default_members": [
"foo 0.1.0 ([..])"
],
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -3361,6 +3403,9 @@ fn filter_platform() {
"workspace_members": [
"foo 0.1.0 (path+file:[..]foo)"
],
"workspace_default_members": [
"foo 0.1.0 (path+file:[..]foo)"
],
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -3480,6 +3525,7 @@ fn filter_platform() {
$NORMAL_DEP
],
"workspace_members": "{...}",
"workspace_default_members": "{...}",
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -3561,6 +3607,7 @@ fn filter_platform() {
$NORMAL_DEP
],
"workspace_members": "{...}",
"workspace_default_members": "{...}",
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -3645,6 +3692,7 @@ fn filter_platform() {
$NORMAL_DEP
],
"workspace_members": "{...}",
"workspace_default_members": "{...}",
"resolve": {
"nodes": [
{
Expand Down Expand Up @@ -3759,6 +3807,7 @@ fn dep_kinds() {
{
"packages": "{...}",
"workspace_members": "{...}",
"workspace_default_members": "{...}",
"target_directory": "{...}",
"version": 1,
"workspace_root": "{...}",
Expand Down Expand Up @@ -3874,6 +3923,7 @@ fn dep_kinds_workspace() {
{
"packages": "{...}",
"workspace_members": "{...}",
"workspace_default_members": "{...}",
"target_directory": "[..]/foo/target",
"version": 1,
"workspace_root": "[..]/foo",
Expand Down Expand Up @@ -4187,6 +4237,11 @@ fn workspace_metadata_with_dependencies_no_deps_artifact() {
"artifact 0.5.0 (path+file://[..]/foo/artifact)",
"baz 0.5.0 (path+file://[..]/foo/baz)"
],
"workspace_default_members": [
"bar 0.5.0 (path+file://[..]/foo/bar)",
"artifact 0.5.0 (path+file://[..]/foo/artifact)",
"baz 0.5.0 (path+file://[..]/foo/baz)"
],
"workspace_root": "[..]/foo"
}
"#,
Expand Down

0 comments on commit f43e6d9

Please sign in to comment.