# Chart validation

**URL:** <https://forum.katalon.com/t/chart-validation/31967>\
**Category:** Web Testing\
**Tags:** web-testing, katalon-studio\
**Created:** [August 22, 2019, 9:55am UTC](https://forum.katalon.com/t/chart-validation/31967 "2019-08-22T09:55:00Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![habinata001](https://avatars.discourse-cdn.com/v4/letter/h/3ec8ea/32.png) [@habinata001](https://forum.katalon.com/u/habinata001)\
**Post date:** [August 22, 2019, 9:55am UTC](https://forum.katalon.com/t/chart-validation/31967/1 "2019-08-22T09:55:00Z")

</div>

Hi, I hope someone can give me a solution with the problem I am having.  
I want to do testing charts with catalon, I have searched but have not found a solution that helps me, the problem I face is :

1. can’t capture the chart that I will test.
2. validation of data displayed by charts with existing tables.
3. validation of the size of the charts that appear.  
someone please help, i need a solution. Thanks

---

<div class="post-metadata">

**Author:** ![habinata001](https://avatars.discourse-cdn.com/v4/letter/h/3ec8ea/32.png) [@habinata001](https://forum.katalon.com/u/habinata001)\
**Post date:** [August 22, 2019, 10:01am UTC](https://forum.katalon.com/t/chart-validation/31967/2 "2019-08-22T10:01:07Z")

</div>

![Capture](https://europe1.discourse-cdn.com/katalon/original/2X/d/da7b428bdebe71476fc9b30642e64b67de6449f0.png) ![Capture1](https://europe1.discourse-cdn.com/katalon/original/2X/f/fe9ec9c97109bca4dfb1f91d376a6dab9034ab7a.png)

---

<div class="post-metadata">

**Author:** ![habinata001](https://avatars.discourse-cdn.com/v4/letter/h/3ec8ea/32.png) [@habinata001](https://forum.katalon.com/u/habinata001)\
**Post date:** [August 23, 2019, 7:10am UTC](https://forum.katalon.com/t/chart-validation/31967/3 "2019-08-23T07:10:13Z")

</div>

does anyone know or catalon does not support to do a test on a pie chart or bar graph ??

---

<div class="post-metadata">

**Author:** ![Russ\_Thomas](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/russ_thomas/32/11884_2.png) [@Russ\_Thomas](https://forum.katalon.com/u/Russ_Thomas)\
**Post date:** [August 23, 2019, 12:13pm UTC](https://forum.katalon.com/t/chart-validation/31967/4 "2019-08-23T12:13:29Z")

</div>

Katalon cannot test the internal parts of a `canvas` element – they are in essence scribbles on a screen. There is nothing in the WebUI API that can help.

However, you can compare the output visually:

> [@Visual Testing in Katalon Studio](http://forum.katalon.com/t/visual-testing-in-katalon-studio/13361):
>
> I have created a project at [GitHub - kazurayam/VisualTestingInKatalonStudio: This is a Katalon Studio project which performs 2 ways of screenshot-comparison testing for WebUI in full automation. Twins mode compares 2 host names at a time. Chronos mode compares the current view of a AUT to the previous one. You can make your own Katalon Studio project capable of the same screenshot-comparison. approach. Instruction provided.](https://github.com/kazurayam/VisualTestingInKatalonStudio) Please refer to this Github repository for running codes and descript…

---

<div class="post-metadata">

**Author:** ![kazurayam](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/kazurayam/32/333_2.png) [@kazurayam](https://forum.katalon.com/u/kazurayam)\
**Post date:** [August 23, 2019, 2:23pm UTC](https://forum.katalon.com/t/chart-validation/31967/5 "2019-08-23T14:23:33Z")

</div>

The following post describes a simpler method of taking screenshots of an anonymous Web element and comparing the images.

> [@Comparing Screenshots of а WebElement](http://forum.katalon.com/t/comparing-screenshots-of-webelement/14060):
>
> I have made a demo project at [GitHub - kazurayam/ComparingScreenshotsOfWebElement at 0.2.0](https://github.com/kazurayam/ComparingScreenshotsOfWebElement/tree/0.2.0) This project proposes a set of Custom Keywords which enable you to test arbitrary HTML elements visually by taking and comparing screenshots in various ways. Problem to solve What is built-in Katalon Studio provides a limited number of built-in keywords for testing web pages visually. [WebUI.verifyImagePresent(TestObject expected)](https://docs.katalon.com/katalon-studio/docs/webui-verify-image-present.html)[WebUI.takeScreenshot(File)](https://docs.katalon.com/katalon-studio/docs/webui-take-screenshot.html)Shortages I would enumerate shortages of t…

---

<div class="post-metadata">

**Author:** ![kazurayam](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/kazurayam/32/333_2.png) [@kazurayam](https://forum.katalon.com/u/kazurayam)\
**Post date:** [August 23, 2019, 2:29pm UTC](https://forum.katalon.com/t/chart-validation/31967/6 "2019-08-23T14:29:09Z")

</div>

> [@habinata001](#):
>
> - can’t capture the chart that I will test.
> - validation of data displayed by charts with existing tables.
> - validation of the size of the charts that appear.

You can take screenshot of any web element as [Comparing Screenshots of а WebElement](http://forum.katalon.com/t/comparing-screenshots-of-webelement/14060) describes.

You can check the width and hight of the PNG image taken — you need to write some lines of Groovy script your self.

> validation of data displayed by charts with existing tables.

This requirement is stated solemnly, but ambiguous. It does not describe what you can/should do. I would suggest to you to reword this sentence into something executable for you.

If you are interested in the behavior of charting software in detail, it is out of the scope which Katalon Studio can cover. You would want to test the JavaScript functions directly. To accomplish it, you need to look at different approach. Possibly you should look at unit-testing frameworks for JavaScript; e.g. [QUnit](https://qunitjs.com/).

---

<div class="post-metadata">

**Author:** ![habinata001](https://avatars.discourse-cdn.com/v4/letter/h/3ec8ea/32.png) [@habinata001](https://forum.katalon.com/u/habinata001)\
**Post date:** [August 24, 2019, 8:02am UTC](https://forum.katalon.com/t/chart-validation/31967/7 "2019-08-24T08:02:58Z")

</div>

ok, thank you all for your reply and solution. I will try it

---

<div class="post-metadata">

**Author:** ![albert.vu](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/albert.vu/32/20595_2.png) [@albert.vu](https://forum.katalon.com/u/albert.vu)\
**Post date:** [August 8, 2022, 7:40am UTC](https://forum.katalon.com/t/chart-validation/31967/8 "2022-08-08T07:40:08Z")

</div>

Archived on August 8, 2022, 7:40am UTC


