diff options
| author | Guillaume Gomez <guillaume.gomez@huawei.com> | 2022-08-17 12:55:09 +0200 |
|---|---|---|
| committer | Guillaume Gomez <guillaume.gomez@huawei.com> | 2022-08-18 11:00:21 +0200 |
| commit | d3d9e223e2d9d12ca68e48b5d1e0adf96793cca7 (patch) | |
| tree | d591b9e3683806513f29e320a9b9ec9e94d284fc /src/test/rustdoc-json/impls | |
| parent | 57c85bd97da336a2199d1b157fb18e70efcafd35 (diff) | |
Update rustdoc-json test files
Diffstat (limited to 'src/test/rustdoc-json/impls')
| -rw-r--r-- | src/test/rustdoc-json/impls/auto.rs | 6 | ||||
| -rw-r--r-- | src/test/rustdoc-json/impls/blanket_with_local.rs | 8 | ||||
| -rw-r--r-- | src/test/rustdoc-json/impls/import_from_private.rs | 16 |
3 files changed, 15 insertions, 15 deletions
diff --git a/src/test/rustdoc-json/impls/auto.rs b/src/test/rustdoc-json/impls/auto.rs index fb32d7c31bc..50d85241427 100644 --- a/src/test/rustdoc-json/impls/auto.rs +++ b/src/test/rustdoc-json/impls/auto.rs @@ -12,7 +12,7 @@ impl Foo { } // Testing spans, so all tests below code -// @is auto.json "$.index[*][?(@.kind=='impl' && @.inner.synthetic==true)].span" null -// @is - "$.index[*][?(@.docs=='has span')].span.begin" "[10, 0]" -// @is - "$.index[*][?(@.docs=='has span')].span.end" "[12, 1]" +// @is "$.index[*][?(@.kind=='impl' && @.inner.synthetic==true)].span" null +// @is "$.index[*][?(@.docs=='has span')].span.begin" "[10, 0]" +// @is "$.index[*][?(@.docs=='has span')].span.end" "[12, 1]" pub struct Foo; diff --git a/src/test/rustdoc-json/impls/blanket_with_local.rs b/src/test/rustdoc-json/impls/blanket_with_local.rs index a3d55b35f00..2fb4a84b9a6 100644 --- a/src/test/rustdoc-json/impls/blanket_with_local.rs +++ b/src/test/rustdoc-json/impls/blanket_with_local.rs @@ -1,11 +1,11 @@ // Test for the ICE in rust/83718 // A blanket impl plus a local type together shouldn't result in mismatched ID issues -// @has blanket_with_local.json "$.index[*][?(@.name=='Load')]" +// @has "$.index[*][?(@.name=='Load')]" pub trait Load { - // @has - "$.index[*][?(@.name=='load')]" + // @has "$.index[*][?(@.name=='load')]" fn load() {} - // @has - "$.index[*][?(@.name=='write')]" + // @has "$.index[*][?(@.name=='write')]" fn write(self) {} } @@ -14,5 +14,5 @@ impl<P> Load for P { fn write(self) {} } -// @has - "$.index[*][?(@.name=='Wrapper')]" +// @has "$.index[*][?(@.name=='Wrapper')]" pub struct Wrapper {} diff --git a/src/test/rustdoc-json/impls/import_from_private.rs b/src/test/rustdoc-json/impls/import_from_private.rs index ef4d8aa39f8..a34046ac12f 100644 --- a/src/test/rustdoc-json/impls/import_from_private.rs +++ b/src/test/rustdoc-json/impls/import_from_private.rs @@ -4,21 +4,21 @@ #![no_core] mod bar { - // @set baz = import_from_private.json "$.index[*][?(@.kind=='struct')].id" + // @set baz = "$.index[*][?(@.kind=='struct')].id" pub struct Baz; - // @set impl = - "$.index[*][?(@.kind=='impl')].id" + // @set impl = "$.index[*][?(@.kind=='impl')].id" impl Baz { - // @set doit = - "$.index[*][?(@.kind=='method')].id" + // @set doit = "$.index[*][?(@.kind=='method')].id" pub fn doit() {} } } -// @set import = - "$.index[*][?(@.kind=='import')].id" +// @set import = "$.index[*][?(@.kind=='import')].id" pub use bar::Baz; // FIXME(adotinthevoid): Use hasexact once #99474 lands -// @has - "$.index[*][?(@.kind=='module')].inner.items[*]" $import -// @is - "$.index[*][?(@.kind=='import')].inner.id" $baz -// @has - "$.index[*][?(@.kind=='struct')].inner.impls[*]" $impl -// @has - "$.index[*][?(@.kind=='impl')].inner.items[*]" $doit +// @has "$.index[*][?(@.kind=='module')].inner.items[*]" $import +// @is "$.index[*][?(@.kind=='import')].inner.id" $baz +// @has "$.index[*][?(@.kind=='struct')].inner.impls[*]" $impl +// @has "$.index[*][?(@.kind=='impl')].inner.items[*]" $doit |
