Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Add staged_api for tests
  • Loading branch information
jsha committed Jan 17, 2022
commit ae99e23c111a811e7edd886c74b5dc6417dd02d6
13 changes: 13 additions & 0 deletions src/test/rustdoc-gui/headings.goml
Original file line number Diff line number Diff line change
Expand Up @@ -154,3 +154,16 @@ assert-css: ("h2#top-doc-prose-title", {"font-size": "20.8px"})
assert-css: ("h2#top-doc-prose-title", {"border-bottom-width": "1px"})
assert-css: ("h3#top-doc-prose-sub-heading", {"font-size": "18.4px"})
assert-css: ("h3#top-doc-prose-sub-heading", {"border-bottom-width": "1px"})

goto: file://|DOC_PATH|/staged_api/struct.Foo.html
show-text: true
local-storage: {"rustdoc-theme": "light", "rustdoc-use-system-theme": "false"}
assert-css: (".since", {"color": "rgb(128, 128, 128)"})

local-storage: {"rustdoc-theme": "dark", "rustdoc-use-system-theme": "false"}
reload:
assert-css: (".since", {"color": "rgb(128, 128, 128)"})

local-storage: {"rustdoc-theme": "ayu", "rustdoc-use-system-theme": "false"}
reload:
assert-css: (".since", {"color": "rgb(128, 128, 128)"})
7 changes: 7 additions & 0 deletions src/test/rustdoc-gui/src/staged_api/Cargo.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# This file is automatically @generated by Cargo.
# It is not intended for manual editing.
version = 3

[[package]]
name = "staged_api"
version = "0.1.0"
11 changes: 11 additions & 0 deletions src/test/rustdoc-gui/src/staged_api/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[package]
name = "staged_api"
version = "0.1.0"
edition = "2021"

[lib]
path = "lib.rs"

[features]
default = ["some_feature"]
some_feature = []
10 changes: 10 additions & 0 deletions src/test/rustdoc-gui/src/staged_api/lib.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#![feature(staged_api)]
#![stable(feature = "some_feature", since = "1.3.5")]

#[stable(feature = "some_feature", since = "1.3.5")]
pub struct Foo {}

impl Foo {
#[stable(feature = "some_feature", since = "1.3.5")]
pub fn bar() {}
}