# How to setting up to debug custom gradle plugin

**URL:** <https://discuss.gradle.org/t/how-to-setting-up-to-debug-custom-gradle-plugin/13846>\
**Category:** Help/Discuss\
**Created:** [January 16, 2016, 1:00pm UTC](https://discuss.gradle.org/t/how-to-setting-up-to-debug-custom-gradle-plugin/13846 "2016-01-16T13:00:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![SamYStudiO](https://avatars.discourse-cdn.com/v4/letter/s/da6949/32.png) [@SamYStudiO](https://discuss.gradle.org/u/SamYStudiO)\
**Post date:** [January 16, 2016, 1:00pm UTC](https://discuss.gradle.org/t/how-to-setting-up-to-debug-custom-gradle-plugin/13846/1 "2016-01-16T13:00:07Z")

</div>

Hi,

i’m pretty new with gradle and groovy/java but i’m trying developing a custom gradle plugin. I’m struggling setting up for testing my plugin, actually i use 2 different projects (in IntelliJ), one for my plugin and one for testing. When i want to test my plugin i upload artifact to mavelLocal and then switch project to refresh dependencies from my test project and run the task i want to test. I know this is bad since i cant get much info when i get an error.  
So what’s the right workflow to debug a plugin maybe having a subproject in my plugin project for testing and/or using unit test?

Thanks for help!

---

<div class="post-metadata">

**Author:** ![Gary\_Hale](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/gary_hale/32/7647_2.png) [@Gary\_Hale](https://discuss.gradle.org/u/Gary_Hale)\
**Post date:** [January 18, 2016, 2:47pm UTC](https://discuss.gradle.org/t/how-to-setting-up-to-debug-custom-gradle-plugin/13846/2 "2016-01-18T14:47:05Z")

</div>

I would encourage you to take a look at the [Gradle Test Kit](https://docs.gradle.org/current/userguide/test_kit.html) which allows you to create functional tests for your plugins. It’s relatively new and still has a few rough edges, but it’s quite usable and works well.
