Skip to content

Rewrite plugin in kotlin#24

Closed
badoualy wants to merge 2 commits intobrowserstack:masterfrom
badoualy:dev-kotlin
Closed

Rewrite plugin in kotlin#24
badoualy wants to merge 2 commits intobrowserstack:masterfrom
badoualy:dev-kotlin

Conversation

@badoualy
Copy link

@badoualy badoualy commented Apr 18, 2020

Hi,

I rewrote the plugin in Kotlin and optimised some part:

  • Injecting the extension in the task => no need to copy paste every properties anymore
  • Using register instead of create task. The task won't be created until actually used (see gradle doc)

I didn't touch the json/http packages, should probably but rewritten with retrofit/moshi one day for maintanability.

I'm using it in locale and it works fine, feel free to test.
If you prefer to keep it in java, just close the PR.

Some notes:

  • Deleted the deprecated tasks
  • app and testSuite properties are not implicitly saved and passed anymore. The calling function now saves the value and pass it to next functions
  • I added the project capabilities as requested in Add project parameters to EspressoTask #23
  • Bumped the android gradle plugins to 3.6.3

I also added a parameter to poll the end of the test in my local fork. Let me know if you're interested in merging that as well.
The process is holding until the execution is finished. The task polls at a regular interval to check the status. Then it downloads the test result file in local test-results directory

@badoualy
Copy link
Author

badoualy commented May 9, 2020

For anyone interested:
https://github.com/badoualy/browserstack-gradle-plugin

Also added:

  • Possibility to wait for build completion before finishing task
  • Task to download tests results (screenshots, video, ...)

@badoualy badoualy closed this May 9, 2020
@badoualy badoualy deleted the dev-kotlin branch May 9, 2020 07:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant