# Generate Test Scripts in Java

**URL:** <https://forum.katalon.com/t/generate-test-scripts-in-java/17333>\
**Category:** Web Testing\
**Tags:** web-testing, katalon-studio\
**Created:** [January 8, 2019, 10:25am UTC](https://forum.katalon.com/t/generate-test-scripts-in-java/17333 "2019-01-08T10:25:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![kumarvinay149](https://avatars.discourse-cdn.com/v4/letter/k/8491ac/32.png) [@kumarvinay149](https://forum.katalon.com/u/kumarvinay149)\
**Post date:** [January 8, 2019, 10:25am UTC](https://forum.katalon.com/t/generate-test-scripts-in-java/17333/1 "2019-01-08T10:25:31Z")

</div>

Hi,

I’m new to Katalon. I need to know how to generate test cases in java instead of Groovy.

---

<div class="post-metadata">

**Author:** ![Mate\_Mrse](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/mate_mrse/32/345_2.png) [@Mate\_Mrse](https://forum.katalon.com/u/Mate_Mrse)\
**Post date:** [January 8, 2019, 10:42am UTC](https://forum.katalon.com/t/generate-test-scripts-in-java/17333/2 "2019-01-08T10:42:57Z")

</div>

Just write the scripts in Java instead of Groovy. It should work.

---

<div class="post-metadata">

**Author:** ![kumarvinay149](https://avatars.discourse-cdn.com/v4/letter/k/8491ac/32.png) [@kumarvinay149](https://forum.katalon.com/u/kumarvinay149)\
**Post date:** [January 8, 2019, 10:56am UTC](https://forum.katalon.com/t/generate-test-scripts-in-java/17333/3 "2019-01-08T10:56:45Z")

</div>

I’m using web recorder. So, where I need to change in settings to generate scripts in java instead of Groovy

---

<div class="post-metadata">

**Author:** ![Ibus](https://avatars.discourse-cdn.com/v4/letter/i/e9a140/32.png) [@Ibus](https://forum.katalon.com/u/Ibus)\
**Post date:** [January 8, 2019, 1:26pm UTC](https://forum.katalon.com/t/generate-test-scripts-in-java/17333/4 "2019-01-08T13:26:13Z")

</div>

nowhere. groovy support plain java code (but java doesn’t understand groovy without importing needed libs).  
so, generate the scripts as you like and feel free to complicate them in plain java syntax by manually editing

---

<div class="post-metadata">

**Author:** ![Brandon\_Hein](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/brandon_hein/32/1092_2.png) [@Brandon\_Hein](https://forum.katalon.com/u/Brandon_Hein)\
**Post date:** [January 8, 2019, 6:00pm UTC](https://forum.katalon.com/t/generate-test-scripts-in-java/17333/5 "2019-01-08T18:00:11Z")

</div>

> [@kumarvinay149](#):
>
> I’m using web recorder. So, where I need to change in settings to generate scripts in java instead of Groovy

I don’t think that there’s an option for the web recorder to generate Java code. If you want to do things in Java, you will need to locate/manipulate elements with hand-written code (which is what you should be doing anyway once you are familiar with the tool). Web recording is a handy, beginner-friendly feature, but eventually you will want to write everything yourself anyway. Feel free to implement everything in Java, that’s what I do as well! 🙂
