-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(rules): add fieldset legend [H71]
- Loading branch information
Showing
8 changed files
with
67 additions
and
7 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "accessibility-rs" | ||
version = "0.0.36" | ||
version = "0.0.37" | ||
authors = ["The A11yWatch Project Developers", "Jeff Mendez <[email protected]>"] | ||
edition = "2021" | ||
license = "MIT OR Apache-2.0" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
//! Test for fieldsets. | ||
use accessibility_rs::AuditConfig; | ||
use maud::html; | ||
|
||
#[test] | ||
/// anchor contains single img element without alt | ||
fn _audit_missing_fieldset_legend() { | ||
let m = html! { | ||
fieldset { | ||
legend { "" }; | ||
input type="radio" id="shakesp" name="hamlet" checked="checked" value="a"; | ||
label for="shakesp" { "William Shakespeare" }; | ||
} | ||
}; | ||
|
||
let audit = accessibility_rs::audit(AuditConfig::basic(&m.into_string())); | ||
|
||
let valid = !audit | ||
.iter() | ||
.any(|x| x.code == "WCAGAAA.Principle1.Guideline1_3.H71"); | ||
|
||
assert_eq!(valid, false) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
pub mod anchor; | ||
pub mod applet; | ||
pub mod fieldset; | ||
pub mod heading; | ||
pub mod html; | ||
pub mod img; | ||
|