Skip to content

Commit

Permalink
unify tests/samples structure
Browse files Browse the repository at this point in the history
This commit follows the naming pattern we use for the compiler/compiler-ast
module nesting. Note that these tests/samples modules are not published so
these namings are purely for consistency reason and ease of identification.
  • Loading branch information
davissuber committed Mar 25, 2024
1 parent e3edd84 commit b57ab9b
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 18 deletions.
10 changes: 6 additions & 4 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,11 @@ subprojects {
}

apply plugin: 'org.jetbrains.dokka'
tasks.withType(DokkaTaskPartial).configureEach {
outputDirectory.set(new File(buildDir, "docs/partial"))
moduleName.set(project.property("POM_ARTIFACT_ID").toString())
moduleVersion.set(project.property("VERSION_NAME").toString())
if (!project.name.contains("samples") && !project.name.contains("tests")) {
tasks.withType(DokkaTaskPartial).configureEach {
outputDirectory.set(new File(buildDir, "docs/partial"))
moduleName.set(project.property("POM_ARTIFACT_ID").toString())
moduleVersion.set(project.property("VERSION_NAME").toString())
}
}
}
3 changes: 1 addition & 2 deletions samples/sample/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ dependencies {
annotationProcessor deps.butterknifeCompiler
annotationProcessor deps.glideCompiler
annotationProcessor project(':compiler')
implementation project(':samples:sample-lib')
implementation project(':samples-sample-lib')
implementation project(':lib')
implementation deps.glide
implementation deps.stetho
Expand All @@ -47,5 +47,4 @@ dependencies {

testImplementation deps.test.junit
testImplementation deps.test.truth

}
29 changes: 18 additions & 11 deletions settings.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -29,28 +29,35 @@ pluginManagement {
}

rootProject.name = 'motif'
include 'lib'
include 'ast'
include 'compiler'
include 'compiler-ast'
include 'compiler-ksp'
include 'samples:sample'
include 'samples:sample-lib'
include 'samples:sample-kotlin'
include 'samples:sample-kotlin-ksp'
include 'samples:dagger-comparison'
include 'intellij'
include 'intellij-ast'
include 'core'
include 'errormessage'
include 'intellij'
include 'intellij-ast'
include 'lib'
include 'models'
include 'ast'
include 'samples-dagger-comparison'
include 'samples-sample'
include 'samples-sample-kotlin'
include 'samples-sample-kotlin-ksp'
include 'samples-sample-lib'
include 'samples-sample-lib-ksp'
include 'tests'
include 'tests:compiler'
include 'tests-compiler'
include 'viewmodel'
include 'xprocessing'
include 'xprocessing-testing'

project(':compiler-ast').projectDir = file('compiler/ast')
project(':compiler-ksp').projectDir = file('compiler/ksp')
project(':intellij-ast').projectDir = file('intellij/ast')
include ':samples:sample-lib-ksp'
project(':samples-dagger-comparison').projectDir = file('samples/dagger-comparison')
project(':samples-sample').projectDir = file('samples/sample')
project(':samples-sample-kotlin').projectDir = file('samples/sample-kotlin')
project(':samples-sample-kotlin-ksp').projectDir = file('samples/sample-kotlin-ksp')
project(':samples-sample-lib').projectDir = file('samples/sample-lib')
project(':samples-sample-lib-ksp').projectDir = file('samples/sample-lib-ksp')
project(':tests-compiler').projectDir = file('tests/compiler')
2 changes: 1 addition & 1 deletion tests/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ kotlin {
}

dependencies {
kapt project(':tests:compiler')
kapt project(':tests-compiler')
kapt deps.daggerCompiler
implementation project(':core')
implementation project(':lib')
Expand Down

0 comments on commit b57ab9b

Please sign in to comment.