Skip to content

Commit

Permalink
fix showSymbolicQspray
Browse files Browse the repository at this point in the history
  • Loading branch information
stla committed Apr 22, 2024
1 parent 16a5311 commit 62ad6c7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion R/show.R
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ showSymbolicQspray <- function(
if(isQzero(Qspray)) {
return("0")
}
qspray <- orderedQspray(Qspray)
Qspray <- orderedQspray(Qspray)
monomials <- showMonomials(Qspray@powers)
coeffs <- paste0(
lbrace,
Expand Down
5 changes: 2 additions & 3 deletions tests/testthat/test-show.R
Original file line number Diff line number Diff line change
Expand Up @@ -109,16 +109,15 @@ test_that("showRatioOfQspraysXYZ is OK", {
X <- Qlone(1)
Q <- a*X + (a+b)*X^2
showSymbolicQsprayOption(Q, "showRatioOfQsprays") <-
showRatioOfQspraysXYZ("a")
showRatioOfQspraysXYZ("u")
expect_identical(
Print(Q),
"{ [ a1 + a2 ] } * X^2 + { [ a1 ] } * X "
"{ [ u1 + u2 ] } * X^2 + { [ u1 ] } * X "
)
showSymbolicQsprayOption(Q, "showSymbolicQspray") <-
showSymbolicQsprayABCXYZ("b", "Z")
expect_identical(
Print(Q),
"{ [ b1 + b2 ] } * Z^2 + { [ b1 ] } * Z "
)

})

0 comments on commit 62ad6c7

Please sign in to comment.