New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow overriding a Dokka version in integration tests #3585
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can indeed come in handy 👍
199d6be
to
6dbe661
Compare
dokkaBuild.androidSdkDir.orNull?.let { androidSdkDir -> | ||
environment("ANDROID_HOME", androidSdkDir.invariantSeparatorsPath) | ||
fun environmentProvider(name: String, provider: Provider<out Any>) { | ||
inputs.property(name, provider) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@adam-enko FYI, without adding properties which are passed to environment
to inputs
tasks will always stay up-to-date
when those properties are changed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've tested it, works well both with published and local versions of Dokka 👍
An addition for #3583.
For UI showcase project, after PR is merged, it will be possible to run it like this:
It's also possible to add
org.jetbrains.dokka.integration_test.dokkaVersionOverride=2.0.0-dev-329
todokka-integration-tests/gradle.properties
(but, it's less recommended, as it could be unnoticed and affect tests behaviour)Note: PR is based on master and not
ui-test-project
branch, sotestUiShowcaseProject
will be not available.Note regarding implementation:
ui-showcase
project. Additionally it could be useful for reproducing bugs with older versions if needed via just property;project.version
to overrideDOKKA_VERSION
and then do the logic based on it - but it will cause rebuilding of all artefacts (because ofdevMavenPublish
). It's possible to overcome this, but I didn't want to change a lot of code;DOKKA_VERSION
for detecting some override could cause some unknown issues;additive
change for this specific use case.