Skip to content

Commit

Permalink
add image tests
Browse files Browse the repository at this point in the history
  • Loading branch information
archmoj committed Nov 13, 2020
1 parent 9e63c04 commit 7a6fd0f
Show file tree
Hide file tree
Showing 7 changed files with 460 additions and 0 deletions.
Binary file added test/image/baselines/ticklabelposition-0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added test/image/baselines/ticklabelposition-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added test/image/baselines/ticklabelposition-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
138 changes: 138 additions & 0 deletions test/image/mocks/ticklabelposition-0.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
{
"data": [{
"xaxis": "x",
"yaxis": "y",
"x": [0, 1000],
"y": [1e-1, 1e+6]
}, {
"xaxis": "x2",
"yaxis": "y2",
"x": [0, 1000],
"y": [1e-1, 1e+6]
}, {
"xaxis": "x3",
"yaxis": "y3",
"x": [0, 1000],
"y": [1e-1, 1e+6]
}, {
"xaxis": "x4",
"yaxis": "y4",
"x": [0, 1000],
"y": [1e-1, 1e+6]
}],
"layout": {
"xaxis": {
"anchor": "y",
"domain": [0, 0.475],
"side": "bottom",
"ticks": "outside",
"ticklabelposition": "outside right",
"tickfont": { "size": 16 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"yaxis": {
"anchor": "x",
"domain": [0, 0.475],
"autorange": "reversed",
"type": "log",
"side": "left",
"ticks": "inside",
"ticklabelposition": "outside top",
"tickfont": { "size": 20 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"xaxis2": {
"anchor": "y2",
"domain": [0.525, 1],
"autorange": "reversed",
"side": "bottom",
"ticks": "inside",
"ticklabelposition": "outside right",
"tickfont": { "size": 20 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"yaxis2": {
"anchor": "x2",
"domain": [0, 0.475],
"type": "log",
"side": "right",
"ticks": "inside",
"ticklabelposition": "outside top",
"tickfont": { "size": 16 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"xaxis3": {
"anchor": "y3",
"domain": [0.525, 1],
"side": "top",
"ticks": "outside",
"ticklabelposition": "outside left",
"tickfont": { "size": 20 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"yaxis3": {
"anchor": "x3",
"domain": [0.525, 1],
"autorange": "reversed",
"type": "log",
"side": "right",
"ticks": "outside",
"ticklabelposition": "outside bottom",
"tickfont": { "size": 16 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"xaxis4": {
"anchor": "y4",
"domain": [0, 0.475],
"autorange": "reversed",
"side": "top",
"ticks": "inside",
"ticklabelposition": "outside right",
"tickangle": -60,
"tickfont": { "size": 16 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"yaxis4": {
"anchor": "x4",
"domain": [0.525, 1],
"type": "log",
"side": "left",
"ticks": "inside",
"ticklabelposition": "outside bottom",
"tickangle": 30,
"tickfont": { "size": 16 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"font": {
"family": "Raleway"
},
"plot_bgcolor": "lightblue",
"showlegend": false,
"width": 1000,
"height": 1000
}
}
149 changes: 149 additions & 0 deletions test/image/mocks/ticklabelposition-1.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,149 @@
{
"data": [{
"xaxis": "x",
"yaxis": "y",
"x": ["20-12-15", "21-01-15"],
"y": [1e-1, 1e+6]
}, {
"xaxis": "x2",
"yaxis": "y2",
"x": ["20-10", "21-06"],
"y": [1e-1, 1e+6]
}, {
"xaxis": "x3",
"yaxis": "y3",
"x": ["20", "23"],
"y": [1e-1, 1e+6]
}, {
"xaxis": "x4",
"yaxis": "y4",
"x": ["01", "10"],
"y": [1e-1, 1e+6]
}],
"layout": {
"xaxis": {
"anchor": "y",
"domain": [0, 0.475],
"type": "date",
"ticklabelmode": "period",
"side": "bottom",
"ticks": "inside",
"ticklabelposition": "inside",
"tickfont": { "size": 16 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"yaxis": {
"anchor": "x",
"domain": [0, 0.475],
"autorange": "reversed",
"type": "log",
"side": "left",
"ticks": "inside",
"ticklabelposition": "inside top",
"tickfont": { "size": 20 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"xaxis2": {
"anchor": "y2",
"domain": [0.525, 1],
"autorange": "reversed",
"type": "date",
"side": "bottom",
"ticks": "inside",
"ticklabelposition": "inside left",
"tickfont": { "size": 20 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"yaxis2": {
"anchor": "x2",
"domain": [0, 0.475],
"type": "log",
"side": "right",
"ticks": "inside",
"ticklabelposition": "inside",
"tickfont": { "size": 16 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"xaxis3": {
"anchor": "y3",
"domain": [0.525, 1],
"type": "date",
"side": "top",
"ticks": "inside",
"ticklabelposition": "inside right",
"tickfont": { "size": 20 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"yaxis3": {
"anchor": "x3",
"domain": [0.525, 1],
"autorange": "reversed",
"type": "log",
"side": "right",
"ticks": "inside",
"ticklabelposition": "inside bottom",
"tickfont": { "size": 16 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"xaxis4": {
"anchor": "y4",
"domain": [0, 0.475],
"autorange": "reversed",
"type": "date",
"ticklabelmode": "period",
"side": "top",
"ticks": "inside",
"ticklabelposition": "inside",
"tickfont": { "size": 16 },
"ticklen": 8,
"tickwidth": 2,
"linewidth": 4,
"gridcolor": "white"
},
"yaxis4": {
"anchor": "x4",
"domain": [0.525, 1],
"type": "log",
"side": "left",
"ticks": "inside",
"ticklabelposition": "inside bottom",
"tickangle": 30,
"tickfont": { "size": 16 },
"ticklen": 16,
"tickwidth": 8,
"linewidth": 1,
"gridcolor": "white"
},
"font": {
"family": "Raleway"
},
"plot_bgcolor": "lightblue",
"showlegend": false,
"width": 1000,
"height": 1000,
"margin": {
"t": 40,
"b": 40,
"l": 40,
"r": 40
}
}
}
Loading

0 comments on commit 7a6fd0f

Please sign in to comment.