diff --git a/.github/workflows/R-CMD-check.yaml b/.github/workflows/R-CMD-check.yaml index 4da952ce20..3b4c41ce21 100644 --- a/.github/workflows/R-CMD-check.yaml +++ b/.github/workflows/R-CMD-check.yaml @@ -35,7 +35,7 @@ jobs: - {os: ubuntu-latest, r: 'oldrel-1'} - {os: ubuntu-latest, r: 'oldrel-2'} - {os: ubuntu-latest, r: 'oldrel-3'} - - {os: ubuntu-latest, r: 'oldrel-4'} + # - {os: ubuntu-latest, r: 'oldrel-4'} # dependency issues with oldrel-4 env: VISUAL_TESTS: ${{ matrix.config.visual_tests }} @@ -63,10 +63,16 @@ jobs: cache-version: 3 needs: check + - name: Set up Python (for reticulate) + if: matrix.config.visual_tests == true + uses: actions/setup-python@v4 + with: + python-version: '3.11' + - name: Install kaleido if: matrix.config.visual_tests == true run: | - Rscript -e 'library(reticulate); use_python(install_python()); py_install(c("kaleido", "plotly"))' + Rscript -e 'library(reticulate); use_python(Sys.which("python")); py_install(c("kaleido", "plotly"))' # Run test() before R CMD check since, for some reason, rcmdcheck::rcmdcheck() skips vdiffr tests - name: Run Tests diff --git a/DESCRIPTION b/DESCRIPTION index 2ac6300cdb..bc1f9f1d19 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -78,11 +78,10 @@ Suggests: rsvg, ggridges LazyData: true -RoxygenNote: 7.3.1 +RoxygenNote: 7.3.2 Encoding: UTF-8 Roxygen: list(markdown = TRUE) Config/Needs/check: - tidyverse/ggplot2, rcmdcheck, devtools, reshape2, diff --git a/NAMESPACE b/NAMESPACE index a181db4ad9..1512977bb3 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -40,6 +40,9 @@ S3method(print,api_grid_local) S3method(print,api_plot) S3method(print,kaleidoScope) S3method(print,plotly_data) +S3method(process,api_image) +S3method(process,api_plot) +S3method(process,default) S3method(to_basic,GeomAbline) S3method(to_basic,GeomAlluvium) S3method(to_basic,GeomAnnotationMap) diff --git a/R/animate.R b/R/animate.R index 25ffa28433..16a6878c5a 100644 --- a/R/animate.R +++ b/R/animate.R @@ -122,7 +122,6 @@ animation_opts_defaults <- function() { } -#' @inheritParams animation_opts #' @param hide remove the animation slider? #' @param ... for `animation_slider`, attributes are passed to a special #' layout.sliders object tied to the animation frames. @@ -149,7 +148,6 @@ animation_slider <- function(p, hide = FALSE, ...) { } -#' @inheritParams animation_slider #' @param label a character string used for the animation button's label #' @export #' @rdname animation diff --git a/R/api_exports.R b/R/api_exports.R index c7123f5590..19445ffe40 100644 --- a/R/api_exports.R +++ b/R/api_exports.R @@ -108,9 +108,6 @@ #' #' } #' - - -#' @rdname api #' @export api_create <- function(x = last_plot(), filename = NULL, fileopt = c("overwrite", "new"), diff --git a/R/ggplotly.R b/R/ggplotly.R index e358bce17a..93d158813c 100644 --- a/R/ggplotly.R +++ b/R/ggplotly.R @@ -1157,8 +1157,9 @@ utils::globalVariables(c("groupDomains", "layers", "prestats_data", "scales", "s # Get the "complete" set of theme elements and their calculated values calculated_theme_elements <- function(plot) { - if (is.function(asNamespace("ggplot2")$complete_theme)) { - theme <- ggplot2::complete_theme(plot$theme) + complete_theme <- ggfun("complete_theme") + if (is.function(complete_theme)) { + theme <- complete_theme(plot$theme) elements <- names(theme) } else { theme <- ggfun("plot_theme")(plot) diff --git a/R/orca.R b/R/orca.R index 1f9f988742..df0398d783 100644 --- a/R/orca.R +++ b/R/orca.R @@ -97,7 +97,6 @@ orca <- function(p, file = "plot.png", format = tools::file_ext(file), #' Orca image export server #' -#' @inheritParams orca #' @param port Sets the server's port number. #' @param keep_alive Turn on keep alive mode where orca will (try to) relaunch server if process unexpectedly exits. #' @param window_max_number Sets maximum number of browser windows the server can keep open at a given time. diff --git a/R/process.R b/R/process.R index bd987b0f21..bb422e6839 100644 --- a/R/process.R +++ b/R/process.R @@ -6,14 +6,17 @@ process <- function(resp) { UseMethod("process") } +#' @export process.default <- function(resp) { json_content(relay_error(resp)) } +#' @export process.api_plot <- function(resp) { json_content(relay_error(resp)) } +#' @export process.api_image <- function(resp) { relay_error(resp) type <- resp[["headers"]][["content-type"]] diff --git a/README.md b/README.md index 7414a8d888..5541472798 100644 --- a/README.md +++ b/README.md @@ -100,7 +100,7 @@ ggplot2 API won’t ever support (e.g., surface, plot_ly(z = ~volcano, type = "surface") ``` -![](https://plot.ly/~brnvg/1134.png) +![](https://plotly.com/~brnvg/1134.png) ## Learn more diff --git a/tests/testthat/_snaps/ggalluvial/stratum-alluvium-color.svg b/tests/testthat/_snaps/ggalluvial/stratum-alluvium-color.svg index d201562295..a03d36e567 100644 --- a/tests/testthat/_snaps/ggalluvial/stratum-alluvium-color.svg +++ b/tests/testthat/_snaps/ggalluvial/stratum-alluvium-color.svg @@ -1 +1 @@ -NoYesMaleFemale1st2nd3rdCrew0500100015002000SurvivedSexClassClass1st2nd3rdCrewTitanic survival by class and sexFreq +NoYesMaleFemale1st2nd3rdCrew0500100015002000SurvivedSexClassClass1st2nd3rdCrewTitanic survival by class and sexFreq diff --git a/tests/testthat/_snaps/ggalluvial/stratum-alluvium.svg b/tests/testthat/_snaps/ggalluvial/stratum-alluvium.svg index f80bf4a8b1..372db14600 100644 --- a/tests/testthat/_snaps/ggalluvial/stratum-alluvium.svg +++ b/tests/testthat/_snaps/ggalluvial/stratum-alluvium.svg @@ -1 +1 @@ -NoYesMaleFemale1st2nd3rdCrew0500100015002000SurvivedSexClassTitanic survival by class and sexFreq +NoYesMaleFemale1st2nd3rdCrew0500100015002000SurvivedSexClassTitanic survival by class and sexFreq diff --git a/tests/testthat/_snaps/ggplot-col/col.svg b/tests/testthat/_snaps/ggplot-col/col.svg index 515c34c421..a3be5dedfa 100644 --- a/tests/testthat/_snaps/ggplot-col/col.svg +++ b/tests/testthat/_snaps/ggplot-col/col.svg @@ -1 +1 @@ -71.4%20.0%48.3%28.6%80.0%51.7%ElementaryHighMiddle0.000.250.500.751.00includedexcludedincludedtypeprop +71.4%20.0%48.3%28.6%80.0%51.7%ElementaryHighMiddle0.000.250.500.751.00includedexcludedincludedtypeprop diff --git a/tests/testthat/_snaps/ggplot-facets/3-panels.svg b/tests/testthat/_snaps/ggplot-facets/3-panels.svg index 00587badec..698153e481 100644 --- a/tests/testthat/_snaps/ggplot-facets/3-panels.svg +++ b/tests/testthat/_snaps/ggplot-facets/3-panels.svg @@ -1 +1 @@ -0.000.250.500.751.000.000.250.500.751.000.000.250.500.751.000.000.250.500.751.00xyabc +0.000.250.500.751.000.000.250.500.751.000.000.250.500.751.000.000.250.500.751.00xyabc diff --git a/tests/testthat/_snaps/ggplot-facets/barley.svg b/tests/testthat/_snaps/ggplot-facets/barley.svg index f302ea46d8..8eb848976d 100644 --- a/tests/testthat/_snaps/ggplot-facets/barley.svg +++ b/tests/testthat/_snaps/ggplot-facets/barley.svg @@ -1 +1 @@ -SvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38Trebi2030405060SvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38Trebiyear19321931yieldvarietyGrand RapidsDuluthUniversity FarmMorrisCrookstonWaseca +SvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38TrebiSvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38Trebi2030405060SvansotaNo. 462ManchuriaNo. 475VelvetPeatlandGlabronNo. 457Wisconsin No. 38Trebiyear19321931yieldvarietyGrand RapidsDuluthUniversity FarmMorrisCrookstonWaseca diff --git a/tests/testthat/_snaps/ggplot-heatmap/tile-no-fill.svg b/tests/testthat/_snaps/ggplot-heatmap/tile-no-fill.svg index 3ffb60481b..54fef9c43c 100644 --- a/tests/testthat/_snaps/ggplot-heatmap/tile-no-fill.svg +++ b/tests/testthat/_snaps/ggplot-heatmap/tile-no-fill.svg @@ -1 +1 @@ -5100.51.01.52.02.5xy +5100.51.01.52.02.5xy diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-counts.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-counts.svg index bcd437959d..26e14cace2 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-counts.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-counts.svg @@ -1 +1 @@ -2345012345wtcount +23450246wtcount diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-dates.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-dates.svg index a7ce21f158..3b37e86f83 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-dates.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-dates.svg @@ -1 +1 @@ -Jan 01Jan 15Feb 01Feb 15Mar 010123monthcount +Jan 01Jan 15Feb 01Feb 15Mar 010123monthcount diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-density.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-density.svg index c65ecdb426..fd604d8a1f 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-density.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-density.svg @@ -1 +1 @@ -23450.00.30.60.91.2wtdensity +23450.00.51.01.5wtdensity diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-dodge.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-dodge.svg index e1d79a991a..22a9743270 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-dodge.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-dodge.svg @@ -1 +1 @@ -23450123factor(vs)01wtcount +234501234factor(vs)01wtcount diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-facets.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-facets.svg index 39ffb737cb..b2bd2e86f8 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-facets.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-facets.svg @@ -1 +1 @@ -23450123452345factor(vs)01wtcount01 +234502462345factor(vs)01wtcount01 diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-identity.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-identity.svg index 311ffb0339..7d8c449852 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-identity.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor-identity.svg @@ -1 +1 @@ -23450123factor(vs)01wtcount +234501234factor(vs)01wtcount diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor.svg index f128d6a4e5..4a98b85937 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-fill-factor.svg @@ -1 +1 @@ -2345012345factor(vs)01wtcount +23450246factor(vs)01wtcount diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-fill.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-fill.svg index 2cf48289ae..de0773ee5a 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-fill.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-fill.svg @@ -1 +1 @@ -2345012345012345countwtcount +234502460246countwtcount diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-fixed-fill-color.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-fixed-fill-color.svg index b82629240f..7e13b056ba 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-fixed-fill-color.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-fixed-fill-color.svg @@ -1 +1 @@ -2345012345wtcount +23450246wtcount diff --git a/tests/testthat/_snaps/ggplot-histogram/histogram-vline.svg b/tests/testthat/_snaps/ggplot-histogram/histogram-vline.svg index 5b4bdf614e..27a445f168 100644 --- a/tests/testthat/_snaps/ggplot-histogram/histogram-vline.svg +++ b/tests/testthat/_snaps/ggplot-histogram/histogram-vline.svg @@ -1 +1 @@ -2345012345wtcount +23450246wtcount diff --git a/tests/testthat/_snaps/ggplot-legend/guide-aes-none.svg b/tests/testthat/_snaps/ggplot-legend/guide-aes-none.svg index 7085010541..cd77554974 100644 --- a/tests/testthat/_snaps/ggplot-legend/guide-aes-none.svg +++ b/tests/testthat/_snaps/ggplot-legend/guide-aes-none.svg @@ -1 +1 @@ -Jan 02Jan 04Jan 06Jan 08Jan 10-2-1012colourMeanQCSeriesASeriesBDateMean +Jan 02Jan 04Jan 06Jan 08Jan 10-2-1012SeriesMeanQCSeriesASeriesBDateValues diff --git a/tests/testthat/_snaps/ggplot-ribbon/ribbon-alpha.svg b/tests/testthat/_snaps/ggplot-ribbon/ribbon-alpha.svg index 35cf2b4e15..14c440608b 100644 --- a/tests/testthat/_snaps/ggplot-ribbon/ribbon-alpha.svg +++ b/tests/testthat/_snaps/ggplot-ribbon/ribbon-alpha.svg @@ -1 +1 @@ -18751900192519501975575.0577.5580.0582.5year +18751900192519501975575.0577.5580.0582.5year diff --git a/tests/testthat/_snaps/ggplot-ribbon/ribbon-colour.svg b/tests/testthat/_snaps/ggplot-ribbon/ribbon-colour.svg index 5d58892410..c0f16e0a9f 100644 --- a/tests/testthat/_snaps/ggplot-ribbon/ribbon-colour.svg +++ b/tests/testthat/_snaps/ggplot-ribbon/ribbon-colour.svg @@ -1 +1 @@ --5.0-2.50.02.55.0576578580582factor(decade)1880189019001910192019301940195019601970diff +-5.0-2.50.02.55.0576578580582factor(decade)1880189019001910192019301940195019601970diff diff --git a/tests/testthat/_snaps/ggplot-ribbon/ribbon-group.svg b/tests/testthat/_snaps/ggplot-ribbon/ribbon-group.svg index ca8c53ce13..9021f288b2 100644 --- a/tests/testthat/_snaps/ggplot-ribbon/ribbon-group.svg +++ b/tests/testthat/_snaps/ggplot-ribbon/ribbon-group.svg @@ -1 +1 @@ --5.0-2.50.02.55.0576578580582diff +-5.0-2.50.02.55.0576578580582diff diff --git a/tests/testthat/_snaps/ggplot-sf/sf-aspect.svg b/tests/testthat/_snaps/ggplot-sf/sf-aspect.svg index b4603aa673..55c95eb7f8 100644 --- a/tests/testthat/_snaps/ggplot-sf/sf-aspect.svg +++ b/tests/testthat/_snaps/ggplot-sf/sf-aspect.svg @@ -1 +1 @@ -84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° N +84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° N diff --git a/tests/testthat/_snaps/ggplot-sf/sf-axis-ticks.svg b/tests/testthat/_snaps/ggplot-sf/sf-axis-ticks.svg index 32baf6c533..5c77bb8a53 100644 --- a/tests/testthat/_snaps/ggplot-sf/sf-axis-ticks.svg +++ b/tests/testthat/_snaps/ggplot-sf/sf-axis-ticks.svg @@ -1 +1 @@ -100 ° W 80 ° W 60 ° W 40 ° W 20 ° W40 ° N50 ° N60 ° N +100 ° W 80 ° W 60 ° W 40 ° W 20 ° W40 ° N50 ° N60 ° N diff --git a/tests/testthat/_snaps/ggplot-sf/sf-fill-text.svg b/tests/testthat/_snaps/ggplot-sf/sf-fill-text.svg index b3ed88da78..c0dd3f4cae 100644 --- a/tests/testthat/_snaps/ggplot-sf/sf-fill-text.svg +++ b/tests/testthat/_snaps/ggplot-sf/sf-fill-text.svg @@ -1 +1 @@ -84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° N0.050.100.150.20AREA +84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° N0.050.100.150.20AREA diff --git a/tests/testthat/_snaps/ggplot-sf/sf-geom-collection.svg b/tests/testthat/_snaps/ggplot-sf/sf-geom-collection.svg index b710b5adf5..64bc029f0a 100644 --- a/tests/testthat/_snaps/ggplot-sf/sf-geom-collection.svg +++ b/tests/testthat/_snaps/ggplot-sf/sf-geom-collection.svg @@ -1 +1 @@ -1234567-0.5-0.4-0.3-0.2-0.1 0.0 +1234567-0.5-0.4-0.3-0.2-0.1 0.0 diff --git a/tests/testthat/_snaps/ggplot-sf/sf-points.svg b/tests/testthat/_snaps/ggplot-sf/sf-points.svg index 6cf62007c5..d67ac10c46 100644 --- a/tests/testthat/_snaps/ggplot-sf/sf-points.svg +++ b/tests/testthat/_snaps/ggplot-sf/sf-points.svg @@ -1 +1 @@ -84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° Nxy +84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° Nxy diff --git a/tests/testthat/_snaps/ggplot-sf/sf-theme-map.svg b/tests/testthat/_snaps/ggplot-sf/sf-theme-map.svg index 48b2fba4c2..7a114eb336 100644 --- a/tests/testthat/_snaps/ggplot-sf/sf-theme-map.svg +++ b/tests/testthat/_snaps/ggplot-sf/sf-theme-map.svg @@ -1 +1 @@ - + diff --git a/tests/testthat/_snaps/ggplot-sf/sf.svg b/tests/testthat/_snaps/ggplot-sf/sf.svg index b4603aa673..55c95eb7f8 100644 --- a/tests/testthat/_snaps/ggplot-sf/sf.svg +++ b/tests/testthat/_snaps/ggplot-sf/sf.svg @@ -1 +1 @@ -84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° N +84 ° W82 ° W80 ° W78 ° W76 ° W34.0 ° N34.5 ° N35.0 ° N35.5 ° N36.0 ° N36.5 ° N diff --git a/tests/testthat/_snaps/ggplot-text/text-colour.svg b/tests/testthat/_snaps/ggplot-text/text-colour.svg index 963ddf31fc..d0daca0f9c 100644 --- a/tests/testthat/_snaps/ggplot-text/text-colour.svg +++ b/tests/testthat/_snaps/ggplot-text/text-colour.svg @@ -1 +1 @@ -HUNTSVILLEMOBILEBIRMINGHAMMONTGOMERYTUCSONPEORIA01020-505DivisionEast South CentralAaMountainAacoord.1coord.2 +HUNTSVILLEMOBILEBIRMINGHAMMONTGOMERYTUCSONPEORIA01020-505DivisionEast South CentralAaMountainAacoord.1coord.2 diff --git a/tests/testthat/_snaps/ggridges/histogram-ridges.svg b/tests/testthat/_snaps/ggridges/histogram-ridges.svg index 6b73b75dc3..89d17fc9bc 100644 --- a/tests/testthat/_snaps/ggridges/histogram-ridges.svg +++ b/tests/testthat/_snaps/ggridges/histogram-ridges.svg @@ -1 +1 @@ -45678setosaversicolorvirginicaSepal.LengthSpecies +45678setosaversicolorvirginicaSepal.LengthSpecies diff --git a/tests/testthat/_snaps/mean-error-bars/error-rect-alpha.svg b/tests/testthat/_snaps/mean-error-bars/error-rect-alpha.svg index 1ef4b2a3de..993e02173b 100644 --- a/tests/testthat/_snaps/mean-error-bars/error-rect-alpha.svg +++ b/tests/testthat/_snaps/mean-error-bars/error-rect-alpha.svg @@ -1 +1 @@ -0246-2.50.02.55.07.5grouponetwoxy +024612345grouponetwoxy diff --git a/tests/testthat/_snaps/plotly-subplot/ggally-ggcorr.svg b/tests/testthat/_snaps/plotly-subplot/ggally-ggcorr.svg index 987f28fdbf..5a72f2d81d 100644 --- a/tests/testthat/_snaps/plotly-subplot/ggally-ggcorr.svg +++ b/tests/testthat/_snaps/plotly-subplot/ggally-ggcorr.svg @@ -1 +1 @@ -v1v2v3v4v5012345612345-1.0-0.50.00.51.0 +v1v2v3v4v5012345612345-1.0-0.50.00.51.0 diff --git a/tests/testthat/_snaps/plotly-subplot/plotly-subplot-ggmatrix.svg b/tests/testthat/_snaps/plotly-subplot/plotly-subplot-ggmatrix.svg index 7c3e107830..cc5b650a26 100644 --- a/tests/testthat/_snaps/plotly-subplot/plotly-subplot-ggmatrix.svg +++ b/tests/testthat/_snaps/plotly-subplot/plotly-subplot-ggmatrix.svg @@ -1 +1 @@ -05101505101556780510150.00.51.01.52.02.52462.02.53.03.54.04.50.00.10.20.30.42.02.53.03.54.04.5Corr:-0.118246Corr:-0.428***Corr:0.872***0.00.51.01.52.02.5Corr:0.963***Corr:-0.366***Corr:0.818***setosaversicolorvirginicaSepal.LengthSepal.WidthPetal.LengthPetal.WidthSpeciesPetal.WidthPetal.LengthSepal.WidthSepal.Lengthsetosaversicolorvirginicasetosaversicolorvirginicasetosaversicolorvirginicasetosaversicolorvirginica +0.02.55.07.50.02.55.07.556780.02.55.07.50.00.51.01.52.02.52462.02.53.03.54.04.50.00.10.20.30.42.02.53.03.54.04.5Corr:-0.118246Corr:-0.428***Corr:0.872***0.00.51.01.52.02.5Corr:0.963***Corr:-0.366***Corr:0.818***setosaversicolorvirginicaSepal.LengthSepal.WidthPetal.LengthPetal.WidthSpeciesPetal.WidthPetal.LengthSepal.WidthSepal.Lengthsetosaversicolorvirginicasetosaversicolorvirginicasetosaversicolorvirginicasetosaversicolorvirginica diff --git a/tests/testthat/_snaps/plotly-subplot/plotly-subplot-width-height.svg b/tests/testthat/_snaps/plotly-subplot/plotly-subplot-width-height.svg index ac7a647b97..627e66e9ae 100644 --- a/tests/testthat/_snaps/plotly-subplot/plotly-subplot-width-height.svg +++ b/tests/testthat/_snaps/plotly-subplot/plotly-subplot-width-height.svg @@ -1 +1 @@ -0.02.55.07.510.0-3-2-1012-2020369xcountcounty +0.02.55.07.5-3-2-1012-2020.02.55.07.510.0xcountcounty diff --git a/tests/testthat/test-plotly.R b/tests/testthat/test-plotly.R index 7b10220293..cad578c45d 100644 --- a/tests/testthat/test-plotly.R +++ b/tests/testthat/test-plotly.R @@ -142,8 +142,7 @@ test_that("Character strings correctly mapped to a positional axis", { letters <- LETTERS[as.numeric(sort(as.character(1:26)))] p <- plot_ly(x = letters, y = seq_along(letters)) %>% add_bars(color = rep(c("a1", "a2"), length.out = 26)) - l <- expect_warning(expect_traces(p, 2, "character-axis"), - regexp = "minimal value for n is 3") + l <- expect_traces(p, 2, "character-axis") expect_equivalent(l$layout$xaxis$type, "category") expect_equivalent(l$layout$xaxis$categoryorder, "array") expect_equivalent(l$layout$xaxis$categoryarray, LETTERS)