Skip to content

Commit

Permalink
test: improve test coverage for font styles
Browse files Browse the repository at this point in the history
- add new font style tests with different variations
- include attribute assertions for each font style test
  • Loading branch information
falcucci committed Sep 21, 2024
1 parent 6b4a05d commit 9a4960f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/test/font_styles.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,7 @@ fn caskaydiacove_nerd_font_italic() {
}

#[test]
#[cfg_attr(target_os = "windows", ignore = "Font not found on windows")]
fn monaspace_xenon_var() {
assert_attributes(
vec![StyleProperty::FontStack(FontStack::Source(
Expand All @@ -210,6 +211,7 @@ fn monaspace_xenon_var() {
}

#[test]
#[cfg_attr(target_os = "windows", ignore = "Font not found on windows")]
fn monaspace_xenon_var_variadic_bold() {
assert_attributes(
vec![
Expand All @@ -231,6 +233,7 @@ fn monaspace_xenon_var_variadic_bold() {
}

#[test]
#[cfg_attr(target_os = "windows", ignore = "Font not found on windows")]
fn monaspace_xenon_var_variadic_italic_buggy() {
assert_attributes(
vec![
Expand All @@ -254,6 +257,7 @@ fn monaspace_xenon_var_variadic_italic_buggy() {
}

#[test]
#[cfg_attr(target_os = "windows", ignore = "Font not found on windows")]
fn monaspace_xenon_var_oblique_minus_10_degrees() {
assert_attributes(
vec![
Expand All @@ -275,6 +279,7 @@ fn monaspace_xenon_var_oblique_minus_10_degrees() {
}

#[test]
#[cfg_attr(target_os = "windows", ignore = "Font not found on windows")]
fn monaspace_xenon_var_oblique_5_degrees_no_italic() {
assert_attributes(
vec![
Expand All @@ -296,6 +301,7 @@ fn monaspace_xenon_var_oblique_5_degrees_no_italic() {
}

#[test]
#[cfg_attr(target_os = "windows", ignore = "Font not found on windows")]
fn monaspace_xenon_var_stretch_113_weight_637_oblique_minus_8_degrees() {
assert_attributes(
vec![
Expand Down

0 comments on commit 9a4960f

Please sign in to comment.