Compare commits

...

15 Commits

Author SHA1 Message Date
Simon Christ
003cafa98a fix 2020-10-20 17:28:10 +02:00
Simon Christ
e9f81e23c8 improve tests 2020-10-20 17:07:53 +02:00
Simon Christ
ebf6e6bafe add tests 2020-10-20 15:51:26 +02:00
Simon Christ
b19515d9af Merge branch 'bbs/artifacts' of https://github.com/JuliaPlots/Plots.jl into bbs/artifacts 2020-10-18 14:09:01 +02:00
Simon Christ
d1c779e49a
Update SnoopCompile.yml 2020-10-17 18:09:56 +02:00
Simon Christ
1ba77d73d7 Merge branch 'bbs/artifacts' of https://github.com/JuliaPlots/Plots.jl into bbs/artifacts 2020-10-17 18:08:37 +02:00
Simon Christ
654efc8acb
Update ci.yml 2020-10-17 18:07:32 +02:00
Simon Christ
4fdbadef16 update CI 2020-10-17 18:02:18 +02:00
Simon Christ
4725014372 correct Project.toml 2020-10-17 17:58:04 +02:00
Simon Christ
90c8fa2b42 replace Artifact by Scratchspace 2020-10-17 17:54:37 +02:00
Simon Christ
21bbf7f1d4 restore === 2020-10-15 22:42:37 +02:00
Simon Christ
80123e1839 fix condition 2020-10-15 22:40:25 +02:00
Simon Christ
0cae99875c fix it 2020-10-15 22:40:25 +02:00
Simon Christ
f1d1cb7f25 check ENV 2020-10-15 22:40:25 +02:00
Simon Christ
2b42a67b28 replace build.jl by Artifacts.toml 2020-10-15 22:40:25 +02:00
6 changed files with 22 additions and 24 deletions

View File

@ -21,8 +21,6 @@ jobs:
fail-fast: false fail-fast: false
matrix: matrix:
version: # NOTE: the versions below should match those in your botconfig version: # NOTE: the versions below should match those in your botconfig
- '1.3'
- '1.4'
- '1.5' - '1.5'
os: # NOTE: should match the os setting of your botconfig os: # NOTE: should match the os setting of your botconfig
- ubuntu-latest - ubuntu-latest

View File

@ -21,7 +21,6 @@ jobs:
fail-fast: false fail-fast: false
matrix: matrix:
version: version:
- '1.3'
- '1' - '1'
- 'nightly' - 'nightly'
os: os:

View File

@ -1,7 +0,0 @@
[plotly]
git-tree-sha1 = "f03dd0451a05a5fdbbcb3e548998a9d7a1ab6368"
lazy = true
[[plotly.download]]
url = "https://cdn.plot.ly/plotly-1.54.2.min.js"
sha256 = "487f1da6b7a1f127de59af8a65bb3fe2c63d709f011afea82896bdce28ecc0f8"

View File

@ -17,7 +17,6 @@ Latexify = "23fbe1c1-3f47-55db-b15f-69d7ec21a316"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
Measures = "442fdcdd-2543-5da2-b0f3-8c86c306513e" Measures = "442fdcdd-2543-5da2-b0f3-8c86c306513e"
NaNMath = "77ba4419-2d1f-58cd-9bb1-8ffee604a2e3" NaNMath = "77ba4419-2d1f-58cd-9bb1-8ffee604a2e3"
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
PlotThemes = "ccf2f8ad-2431-5c83-bf29-c5338b663b6a" PlotThemes = "ccf2f8ad-2431-5c83-bf29-c5338b663b6a"
PlotUtils = "995b91a9-d308-5afd-9ec6-746e21dbc043" PlotUtils = "995b91a9-d308-5afd-9ec6-746e21dbc043"
Printf = "de0858da-6303-5e67-8744-51eddeeeb8d7" Printf = "de0858da-6303-5e67-8744-51eddeeeb8d7"
@ -27,6 +26,7 @@ RecipesBase = "3cdcf5f2-1ef4-517c-9805-6587b60abb01"
RecipesPipeline = "01d81517-befc-4cb6-b9ec-a95719d0359c" RecipesPipeline = "01d81517-befc-4cb6-b9ec-a95719d0359c"
Reexport = "189a3867-3050-52da-a836-e630ba90ab69" Reexport = "189a3867-3050-52da-a836-e630ba90ab69"
Requires = "ae029012-a4dd-5104-9daa-d747884805df" Requires = "ae029012-a4dd-5104-9daa-d747884805df"
Scratch = "6c6a2e73-6563-6170-7368-637461726353"
Showoff = "992d4aef-0814-514b-bc4d-f2e9a6c4116f" Showoff = "992d4aef-0814-514b-bc4d-f2e9a6c4116f"
SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf" SparseArrays = "2f01184e-e22b-5df5-ae63-d93ebab69eaf"
Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2"
@ -52,9 +52,8 @@ RecipesPipeline = "0.1.13"
Reexport = "0.2" Reexport = "0.2"
Requires = "1" Requires = "1"
Showoff = "0.3.1" Showoff = "0.3.1"
StableRNGs = "0.1.1"
StatsBase = "0.32, 0.33" StatsBase = "0.32, 0.33"
julia = "1.3" julia = "1.5"
[extras] [extras]
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f" Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"

View File

@ -1,7 +1,8 @@
using REPL using REPL
using Pkg.Artifacts using Scratch
const plotly_local_file_path = Ref{Union{Nothing, String}}(nothing)
const plotly_local_file_path = Ref("")
function _plots_defaults() function _plots_defaults()
if isdefined(Main, :PLOTS_DEFAULTS) if isdefined(Main, :PLOTS_DEFAULTS)
@ -77,17 +78,12 @@ function __init__()
end end
end end
if get(ENV, "PLOTS_HOST_DEPENDENCY_LOCAL", "false") == true if get(ENV, "PLOTS_HOST_DEPENDENCY_LOCAL", "false") == "true"
artifact_toml = joinpath(@__DIR__, "Artifacts.toml") global plotly_local_file_path[] = joinpath(@get_scratch!("plotly"), "plotly-1.54.2.min.js")
if !isfile(plotly_local_file_path[])
plotly_sha = artifact_hash("plotly", artifact_toml) download("https://cdn.plot.ly/plotly-1.54.2.min.js", plotly_local_file_path[])
if plotly_sha === nothing || !artifact_exists(plotly_sha)
plotly_sha = create_artifact() do artifact_dir
download("https://cdn.plot.ly/plotly-1.54.2.min.js", joinpath(artifact_dir, "plotly-1.54.2.min.js"))
end
end end
plotly_local_file_path[] = joinpath(artifact_path(plotly_sha), "plotly-1.54.2.min.js")
use_local_plotlyjs[] = true use_local_plotlyjs[] = true
end end

View File

@ -11,6 +11,19 @@ import GeometryTypes, GeometryBasics
using Dates using Dates
using RecipesBase using RecipesBase
@testset "Plotly standalone" begin
@test Plots.plotly_local_file_path[] === nothing
temp = Plots.use_local_dependencies[]
withenv("PLOTS_HOST_DEPENDENCY_LOCAL" => true) do
Plots.__init__()
@test Plots.plotly_local_file_path[] isa String
@test isfile(Plots.plotly_local_file_path[])
@test Plots.use_local_dependencies[] = true
end
Plots.plotly_local_file_path[] = nothing
Plots.use_local_dependencies[] = temp
end # testset
include("test_defaults.jl") include("test_defaults.jl")
include("test_axes.jl") include("test_axes.jl")
include("test_axis_letter.jl") include("test_axis_letter.jl")