Skip to content

Commit

Permalink
Merge fd45c30 into ca692d6
Browse files Browse the repository at this point in the history
  • Loading branch information
chali committed Jan 5, 2021
2 parents ca692d6 + fd45c30 commit 5700368
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class GradleDependencyGenerator {
subprojects {
apply plugin: 'maven-publish'
apply plugin: 'ivy-publish'
apply plugin: 'java'
apply plugin: 'java-library'
publishing {
repositories {
Expand All @@ -53,7 +53,7 @@ class GradleDependencyGenerator {
subprojects {
apply plugin: 'maven-publish'
apply plugin: 'ivy-publish'
apply plugin: 'java'
apply plugin: 'java-library'
publishing {
repositories {
Expand Down Expand Up @@ -182,7 +182,7 @@ class GradleDependencyGenerator {
if (node.dependencies) {
block.withPrintWriter { writer ->
writer.println 'dependencies {'
node.dependencies.each { writer.println " compile '${it}'" }
node.dependencies.each { writer.println " api '${it}'" }
writer.println '}'
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@ class GradleDependencyGeneratorSpec extends Specification {

then:
def repo = new File(directory)
new File(repo, 'test.ivy.foo_1_0_0/build.gradle').text.contains 'compile \'test.ivy:bar:1.1.0\''
new File(repo, 'test.ivy.foo_1_0_0/build.gradle').text.contains 'api \'test.ivy:bar:1.1.0\''
new File(repo, 'ivyrepo/test/ivy/foo/1.0.0/foo-1.0.0-ivy.xml').text.contains '<dependency org="test.ivy" name="bar" rev="1.1.0" conf="compile-&gt;default"/>'
}

Expand All @@ -261,7 +261,7 @@ class GradleDependencyGeneratorSpec extends Specification {

then:
def repo = new File(directory)
new File(repo, 'test.maven.foo_1_0_0/build.gradle').text.contains 'compile \'test.maven:bar:1.+\''
new File(repo, 'test.maven.foo_1_0_0/build.gradle').text.contains 'api \'test.maven:bar:1.+\''
def pom = new File(repo, 'mavenrepo/test/maven/foo/1.0.0/foo-1.0.0.pom').text
pom.contains '<groupId>test.maven</groupId>'
pom.contains '<artifactId>bar</artifactId>'
Expand Down

0 comments on commit 5700368

Please sign in to comment.