Commit Graph

65 Commits

Author SHA1 Message Date
Nikolay Krasko 110a9ff600 Fix project configuration: avoid adding test jar as library dependency
For some reason gradle processes "testJar" task differently and collects
artifacts for it during configuration phase. This helps Idea project
configurator understand that there's no need to attach test jar as separate
binary library dependency.

Having compiled module in dependencies results IDEA finds both compiled and
source version of classes. This may cause bad navigation and reindexing.
2017-12-06 19:14:28 +03:00
Alexey Andreev 8514a7706f Remove json.org library, use own JSON parser to parse source maps 2017-11-29 20:08:29 +03:00
Alexander Udalov 79e399942d Use "sourcesJar" task builder for kotlin-reflect sources 2017-11-28 12:46:10 +01:00
Alexander Udalov 3d3ece72d2 Do not add task dependency from "sourcesJar" on "classes"
There doesn't seem to be any problem with collecting sources of the
project separately from compiling the project
2017-11-28 12:45:56 +01:00
Alexander Udalov 200c62b574 Use JvmPackageTable from bootstrap compiler in KotlinModuleShadowTransformer
Instead of generating another copy of it into buildSrc. Also move
KotlinModuleShadowTransformer to kotlin-reflect's build script, to its
only usage
2017-11-28 12:45:56 +01:00
Alexander Udalov a1f895bb1f Rewrite kotlin-reflect build script from Groovy to Kotlin 2017-11-28 12:45:53 +01:00
Alexander Udalov 329fbd8fa8 Extract kotlin-reflect-api module out of kotlin-reflect
This is needed only for faster compilation of the Kotlin project itself
and has no effect on the public artifact
org.jetbrains.kotlin:kotlin-reflect.

The problem this is solving is the rebuild of the project once anything
has been changed in modules in 'core' (even inside function bodies, i.e.
a non-API change). Previously, changes in 'core' led to the compilation
of kotlin-reflect, which led to the rebuild of all modules depending on
kotlin-reflect directly or indirectly (which is almost all modules in
the project) because kotlin-reflect's artifacts are custom-built and the
changes can not be picked up incrementally. But 99.9% of the time the
initial changes in 'core' could not have any effect on the usages of
kotlin-reflect, because classes from those modules are moved to an
internal package in kotlin-reflect and thus are an internal
implementation detail.

Now, changes in 'core' still lead to the compilation of kotlin-reflect
and to the process of building the custom jar. But if a module depends
on kotlin-reflect-api, not kotlin-reflect, then the incremental
difference checker will detect that the module does not have to be
recompiled if there hasn't been any changes to the API of
kotlin-reflect-api. Which means that the module will not be rebuilt on
every change in 'core'.

This commit only introduces the new module. The dependencies
(kotlin-reflect -> kotlin-reflect-api) are replaced in the next commit.
2017-11-28 12:35:48 +01:00
Ilya Chernikov 56542286eb Bring back filtering of jna and shading of jline in embeddable compiler
they were lost during the migration to gradle

(cherry picked from commit 126a6a8)
2017-11-20 19:59:40 +01:00
Mikhail Zarechenskiy b6542caf47 Setup system property for NI tests with parameter -PnewInferenceTests 2017-11-13 16:23:05 +03:00
Alexander Udalov 208e68a968 Move strip-kotlin-annotations script to buildSrc
... and invoke it directly in kotlin-reflect's build file, instead of
running another instance of compiler to evaluate a script. Also only
strip kotlin.Metadata, since it's the only annotation with heavy
metadata on Kotlin-generated class files
2017-11-10 18:58:32 +01:00
Ilya Gorbunov b2627f53a3 Fix resources clashes in ultimate plugin tests
Rollback tests-jar configuration to extend testCompile instead of testRuntime.
Otherwise an unwanted main artifact from the runtime configuration gets added to the
artifacts of tests-jar configuration.

Exclude transitive dependencies of projectTests(":idea")
2017-11-08 19:05:36 +03:00
Ilya Gorbunov 24c982de9b Make project dependency shortcuts return ProjectDependency
to enable further configuration.
2017-11-08 19:03:40 +03:00
Ilya Gorbunov 61b78d7eda Make projectTests type of dependency transitive on testRuntime dependencies
`tests-jar` configuration now extends testRuntime instead of testCompile
(note that testRuntime extends testCompile),
and projectTests() dependency shortcut makes it transitive.

This is required to depend on test utility modules producing `-tests` jar instead of default one
without listing all their transitive dependencies.
2017-11-02 18:19:52 +03:00
Ilya Gorbunov be63f09f8f Remove some workarounds for extra properties and signing,
use new syntax for maven repo definition.
2017-11-01 17:09:10 +03:00
Simon Ogorodnik 0a4860b4d7 Add instrumentation to locate not cleared MockApplication 2017-10-31 20:25:00 +03:00
Alexander Udalov d79b571781 Rename ultimate's GenerateTests -> GenerateUltimateTests, regenerate 2017-10-31 07:36:45 +01:00
Ilya Gorbunov 97cf09b45a Do not fail build on TC when some tests fail, just report problem
Required to have green builds with failing tests muted.
2017-10-24 20:35:47 +03:00
Ilya Chernikov 431d47a605 Fix dependencies rewriting and gradle integration tests after applying rewriting 2017-10-16 21:48:36 +02:00
Ilya Chernikov fb70227868 Move embeddable compiler shading logic to buildSrc, implement rewriteDeps task
the task takes a jar an a shading task (like the one that creates embeddable
compiler) and rewrites jar's dependencies to the shaded ones according the
the shade task.
2017-10-16 21:48:34 +02:00
Ilya Chernikov 5babf89245 Remove original jar artifact from archives when adding a new one by runtimeJar tasks 2017-10-16 21:48:33 +02:00
Ilya Gorbunov 13d6e96c2f Do not pack build.txt into jars, leave it only in artifact zip bundles 2017-10-16 18:48:09 +03:00
Simon Ogorodnik 30853d5f85 Show missing deps when preloaded deps not found 2017-10-12 17:34:55 +03:00
Nikolay Krasko aaa3dd8e70 Don't filter out inner classes when running tests (KT-20684)
#KT-20684 In Progress
2017-10-11 12:43:43 +03:00
Ilya Gorbunov 43e6106791 Bootstrap selection: allow to specify teamcity project with a parameter 2017-10-10 21:00:32 +03:00
Ilya Gorbunov fe9ef04cae Make a task to count dex methods in kotlin-stdlib and kotlin-reflect 2017-10-10 14:48:20 +03:00
Ilya Gorbunov 8b70767d76 Configure pom signing before deployment
Use groovy where kotlin dsl lacks of typed api
2017-10-06 19:50:22 +03:00
Dmitry Jemerov d79b9c1b51 Allow plugin dependencies to be optional (no Maven in Android Studio) 2017-10-06 14:43:22 +02:00
Ilya Gorbunov 887e71a7c1 Provide kotlin bootstrap source options 2017-10-04 20:02:26 +03:00
Ilya Gorbunov 5483de276e Specify bootstrap version with gradle props instead of system props
Make bootstrap dependency version explicit
2017-10-04 20:02:12 +03:00
Ilya Gorbunov b7d21ab4da Use embeddedKotlinVersion to compile buildSrc, but make it possible to override it 2017-10-04 19:27:28 +03:00
Andrey Mischenko 3d8486e8a6 Allow to use Gradle property to configure JDK path 2017-09-26 18:14:45 +02:00
Dmitry Jemerov 09f826b68d Enable UI Designer instrumentation in Gradle build 2017-09-26 14:43:01 +02:00
Ilya Gorbunov c29e44f057 Correct setup for the mavenDeployer 2017-09-20 11:52:03 +02:00
Ilya Gorbunov 4a3c8286a3 Fix developer organization in pom, make artifact manifests same as in libraries 2017-09-20 11:52:03 +02:00
Ilya Gorbunov 678caa5676 Setup project versions
Build parameters (with corresponding project properties):
- build.number (buildNumber) - build number from build server, goes into manifest, by default snapshot
- deployVersion (kotlinVersion, project.version) - version of artifacts, by default build.number
- bootstrap.kotlin.version (bootstrapKotlinVersion) - version of bootstrap compiler
2017-09-20 11:52:01 +02:00
Ilya Chernikov df04efcf14 Rename artifacts, fix dependencies and artifact contents 2017-09-20 11:52:00 +02:00
Ilya Chernikov d61695be55 Fix embeddable compiler dependencies, fix dist task, use runtimeJar...
dependencies where appropriate, some helpers refactoring
2017-09-20 11:52:00 +02:00
Ilya Chernikov b7226951b6 introduce ideaPlugin task as a replacement for idea-plugin...
leave idea-plugin as a reference to the new one for compatibility
2017-09-20 11:51:59 +02:00
Ilya Chernikov 372138977d Fix compiler archives config contents - fixes signing, add some utils 2017-09-20 11:51:58 +02:00
Alexander Udalov 8f5dae8f57 Do not set KOTLIN_HOME env var for tests
Instead, rework the (already suspicious) KotlinPaths-finding code in
PathUtil to support the new model of running tests (the compiler is
split into several jars according to the project structure) instead of
the old one (where class files were not in the jars, but in the out/
directory).

This fixes Java9ModulesIntegrationTest
2017-09-20 11:51:56 +02:00
Ilya Chernikov 51efd717f6 Extract jvm6-specific test utils, add codegen on specific jdk tests 2017-09-20 11:51:54 +02:00
Ilya Chernikov 1862c78bdc Fix projects for gradle integration tests 2017-09-20 11:51:44 +02:00
Ilya Chernikov d92cce6e6a Fix build after rebase on master 2017-09-20 11:51:38 +02:00
Ilya Chernikov 46884bec84 Add missing artifact, fix some deps and publishing 2017-09-20 11:51:38 +02:00
Ilya Chernikov 02ec70e9f1 Fix kotlin-daemon-client project config and publications, fix problem with uploadArchives task 2017-09-20 11:51:32 +02:00
Ilya Chernikov 9df5d53a9d Add classes dirs artifact helpers, minor cleanup 2017-09-20 11:51:29 +02:00
Ilya Chernikov a63d1a53c3 Reduce memory requirements for gradle and js backend tests 2017-09-20 11:51:25 +02:00
Ilya Chernikov c428f12d71 Add Idea Ultimate plugin build 2017-09-20 11:51:25 +02:00
Ilya Chernikov 8c44b62d16 Fix recursive task dependency helpers 2017-09-20 11:51:24 +02:00
Ilya Chernikov 95035b3d72 Fix various tests 2017-09-20 11:51:23 +02:00