Skip to content

Commit

Permalink
add requirejs html tests again
Browse files Browse the repository at this point in the history
  • Loading branch information
kMutagene committed Feb 10, 2023
1 parent c3823a2 commit c5f7108
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tests/Plotly.NET.Tests/HtmlCodegen/SimpleTests.fs
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,14 @@ let ``Html layout tests`` =
"""var layout = {"title":{"text":"Hello world!"},"xaxis":{"title":{"text":"xAxis"},"showgrid":false},"yaxis":{"title":{"text":"yAxis"},"showgrid":false}};"""
|> chartGeneratedContains simpleChart
);
testCase "Expecting cloudflare link" (fun () ->
"""https://cdnjs.cloudflare.com/ajax/libs/require.js"""
|> chartGeneratedContains simpleChart
);
testCase "Expecting require config" (fun () ->
(sprintf """var fsharpPlotlyRequire = requirejs.config({context:'fsharp-plotly',paths:{plotly:'https://cdn.plot.ly/plotly-%s.min'}}) || require;""" Globals.PLOTLYJS_VERSION)
|> chartGeneratedContains simpleChart
);
testCase "Expecting html tags in embedded page only" (fun () ->
["<html>"; "</html>"; "<head>"; "</head>"; "<body>"; "</body>"; "<script type=\"text/javascript\">"; "</script>"]
|> substringListIsInChart simpleChart toEmbeddedHTML
Expand Down

0 comments on commit c5f7108

Please sign in to comment.