GoogleCloudPlatform / gradle-appengine-plugin

Gradle plugin that provides tasks for uploading, running and managing Google App Engine projects
Apache License 2.0
236 stars 60 forks source link

Skip functional tests #282

Closed yuri-sergiichuk closed 7 years ago

yuri-sergiichuk commented 7 years ago

Hi.

Could you please advice how to skip functional tests that gradle-appengine-plugin is trying to run?

The reason for this is that right now I don't have any functional tests, but this plugin automatically starts/stops/etc appengine dev server and it took a lot of time regarding to the average build time.

And I'd like to run functional tests (if any) on my own, i.e. in separate CI job (only for functional tests) as I assume, that they could take a lot of time.

So, the general question is how to disable app engine functional tests?

If it'll help, I use gradle 3.5 and run smth like gradlew build or if only for tests - gradlew check.

Thanks in advance for you help.

patflynn commented 7 years ago

@loosebazooka @luriiSergiichuk I don't think the plugin should be trying to run functional tests for you. Do you have some App Engine integration tests in your project?

loosebazooka commented 7 years ago

I believe this has been the behavior since before we even took over the plugin. There are a couple ways to skip the task however.

  1. from the command line
    ./gradlew build -x appengineFunctionalTest
  2. in the build.gradle, one of the following
    • remove the task from check
      check.dependsOn.remove(appengineFunctionalTest)
    • disable the task (this might still print it out and the start/stop of the server still appear in the task tree)
      appengineFunctionalTest.enabled = false

      In all cases, as far as I can tell, it will not start up the server.

yuri-sergiichuk commented 7 years ago

@patflynn I don't have any right now, so I don't want to waste my time with starting up appengine each time. But even when I'd got any - I do want to run them separately.

@loosebazooka Thanks a lot! I've removed check dependency to the appengineFunctionalTest - that's exactly what I want!