# Perspective Custom Module Testing Environment

**URL:** <https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167>\
**Category:** 3rd Party Modules\
**Created:** [November 17, 2021, 6:17am UTC](https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167 "2021-11-17T06:17:32Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Rvb0073](https://avatars.discourse-cdn.com/v4/letter/r/57b2e6/32.png) [@Rvb0073](https://forum.inductiveautomation.com/u/Rvb0073)\
**Post date:** [November 17, 2021, 6:17am UTC](https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167/1 "2021-11-17T06:17:32Z")

</div>

Hello,  
We are developing a custom HMI component for Perspective.  
One pain point is that we have to completely recompile the MODL module to be able to test it in the Ignition environment.

Is there a way to separately test the ReactJS-based frontend part and the java backend part outside of the Ignition runtime environment, because having to recompile takes time?

Thanks for your replies.

---

<div class="post-metadata">

**Author:** ![victordcq](https://avatars.discourse-cdn.com/v4/letter/v/f6c823/32.png) [@victordcq](https://forum.inductiveautomation.com/u/victordcq)\
**Post date:** [November 17, 2021, 8:22am UTC](https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167/2 "2021-11-17T08:22:34Z")

</div>

if you made a seperate file for your main js you can test that with something like storybooks for example.  
requires quite the restructure tho if you didnt do this from the start so not really worth it if you havent, you gotta test it again on ignition anyways because it jsut works a bit different.  
Storybook is rly fast tho, ive used it quite a bit. But if you have a gateway delegate and stuff you cant rly do that with this.

I believe there was a way to set up a test enviorment too with docker or something but i never bothered (maybe i should idk, doesnt take to long to rebuild and it has to do it there anyways too)

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [November 17, 2021, 3:33pm UTC](https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167/3 "2021-11-17T15:33:08Z")

</div>

You can add a `-Dres.path.<moduleid>=/path/to/directory/` argument to `ignition.conf`; then the gateway will skip loading your resources from the module directly and instead load them from disk. Then you just need to trigger a rebuild of your frontend assets without having to rebuild and reinstall the entire module.

---

<div class="post-metadata">

**Author:** ![Pierre\_ALTOUNIAN](https://avatars.discourse-cdn.com/v4/letter/p/ee59a6/32.png) [@Pierre\_ALTOUNIAN](https://forum.inductiveautomation.com/u/Pierre_ALTOUNIAN)\
**Post date:** [November 29, 2021, 3:28pm UTC](https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167/4 "2021-11-29T15:28:05Z")

</div>

Should the value be assigned to a ‘wrapper.java’ key, which exactly ?  
‘moduleid’ is the ‘name’ in the Config \> System \> Module Configuration page of the gateway ?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [November 29, 2021, 3:43pm UTC](https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167/5 "2021-11-29T15:43:01Z")

</div>

`moduleId` should be the exact value of your module’s ID - whatever is specified in the `module.xml` file. If you’re using one of our plugins, it should be pretty easy to identify.

In 8.x we switched to a reversed qualified DNS style for module IDs, e.g. `moduleId = "com.inductiveautomation.vision"`. We generally recommend that pattern.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [November 29, 2021, 4:00pm UTC](https://forum.inductiveautomation.com/t/perspective-custom-module-testing-environment/53167/6 "2021-11-29T16:00:33Z")

</div>

Absolutely use the reverse qualified DNS style for your module IDs if you ever intend to restrict access to the resulting module. When you get set up to generate license keys through IA’s servers, you will be limited to module ID’s that start with your company’s web address. For example, my module IDs all start with “com.automation\_pros”. (Hyphens have to become underscores to be valid.)
