Expose canvas data to assist in automated testing #10478
generator87
started this conversation in
Ideas
Replies: 1 comment 8 replies
-
You can do this: Chart.getChart(canvasId); With this you get the chart instance for that canvas if it is made which has all the configuration. |
Beta Was this translation helpful? Give feedback.
8 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Currently to test canvas charts using automated testing many are using some screenshot comparison tools which are pain but if it would be possible to easily get json data for the chart canvas then testing would be faster and more reliable. Just imagine some simple javascript like for example document.getElementById("#montlyTemperaturesCanvas") would have return including json data that was used to draw that canvas then automated test could easily parse this and check that correct data was used.
Beta Was this translation helpful? Give feedback.
All reactions