Skip to content

Commit

Permalink
Test math rendering in examples (#2751)
Browse files Browse the repository at this point in the history
Part of #2704
  • Loading branch information
jayhesselberth authored Nov 29, 2024
1 parent 7a6ffe4 commit 6e1613c
Show file tree
Hide file tree
Showing 15 changed files with 62 additions and 2 deletions.
18 changes: 16 additions & 2 deletions R/test.R
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ NULL
#' x <- 4
#' }
#' x # should be 1
#'
#'
#' # \dontshow{} -------------------------------------------------------
#' # never shown, always run
#'
Expand All @@ -145,7 +145,7 @@ NULL
#' # If FALSE, wrapped in if; if TRUE, not seen
#'
#' x <- 1
#'
#'
#' @examplesIf FALSE
#' x <- 2
#' @examplesIf TRUE
Expand Down Expand Up @@ -275,3 +275,17 @@ NULL
#' @keywords internal
#' @family tests
NULL

#' Test case: math rendering in examples
#'
#' @param x \eqn{f(x) > 0}: inline equation
#'
#' @details
#' Display equation:
#'
#' \deqn{y = \alpha + \beta X + \varepsilon}
#'
#' @name test-math-examples
#' @keywords internal
#' @family tests
NULL
1 change: 1 addition & 0 deletions man/index.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-crayon.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-dont.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-figures.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-links.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-lists.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-long-lines.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

33 changes: 33 additions & 0 deletions man/test-math-examples.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-output-styles.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-params.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-sexpr-title.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-tables.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions man/test-verbatim.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions pkgdown/_pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ authors:

template:
bootstrap: 5
math-rendering: mathjax
light-switch: true
bslib:
primary: "#0054AD"
Expand Down

0 comments on commit 6e1613c

Please sign in to comment.