Skip to content

Commit

Permalink
testcases now use newest gradle
Browse files Browse the repository at this point in the history
  • Loading branch information
soloturn committed May 23, 2021
1 parent afdbd3e commit e6e4529
Show file tree
Hide file tree
Showing 29 changed files with 56 additions and 62 deletions.
5 changes: 3 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ build/
src/test/integration/test/.git/
src/test/integration/test/build/
src/test/integration/test/.gradle/
src/test/integration/test/build.gradle
src/test/integration/test/build.gradle.kts
src/test/integration/test/content
.idea/
*.iml
*.iml

3 changes: 0 additions & 3 deletions src/test/integration/contexts/distance-depth/jgitver.gradle

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jgitver {
distanceCalculatorKind = fr.brouillard.oss.jgitver.impl.DistanceCalculator.CalculatorKind.DEPTH
}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jgitver {
distanceCalculatorKind = fr.brouillard.oss.jgitver.impl.DistanceCalculator.CalculatorKind.FIRST_PARENT
}
3 changes: 0 additions & 3 deletions src/test/integration/contexts/distance-log/jgitver.gradle

This file was deleted.

3 changes: 3 additions & 0 deletions src/test/integration/contexts/distance-log/jgitver.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jgitver {
distanceCalculatorKind = fr.brouillard.oss.jgitver.impl.DistanceCalculator.CalculatorKind.LOG
}
3 changes: 0 additions & 3 deletions src/test/integration/contexts/maven-like/jgitver.gradle

This file was deleted.

3 changes: 3 additions & 0 deletions src/test/integration/contexts/maven-like/jgitver.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jgitver {
strategy = fr.brouillard.oss.jgitver.Strategies.MAVEN
}
3 changes: 0 additions & 3 deletions src/test/integration/contexts/merged-branches/jgitver.gradle

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jgitver {
strategy = fr.brouillard.oss.jgitver.Strategies.CONFIGURABLE
}
3 changes: 0 additions & 3 deletions src/test/integration/contexts/policy-latest/jgitver.gradle

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jgitver {
policy = fr.brouillard.oss.jgitver.LookupPolicy.LATEST
}
3 changes: 0 additions & 3 deletions src/test/integration/contexts/policy-nearest/jgitver.gradle

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
jgitver {
policy = fr.brouillard.oss.jgitver.LookupPolicy.NEAREST
}
4 changes: 0 additions & 4 deletions src/test/integration/contexts/tag-regexp/jgitver.gradle

This file was deleted.

4 changes: 4 additions & 0 deletions src/test/integration/contexts/tag-regexp/jgitver.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
jgitver {
strategy = fr.brouillard.oss.jgitver.Strategies.PATTERN
regexVersionTag = "r(.*)"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
./build.sh v1.2-tags-regexp $JGITVER_GRADLE_PLUGIN_VERSION 1.2.3-1
4 changes: 0 additions & 4 deletions src/test/integration/contexts/v1.2-tags-regexp/jgitver.gradle

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
jgitver {
strategy = fr.brouillard.oss.jgitver.Strategies.PATTERN
regexVersionTag = "v(1\\.2.*)"
}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
jgitver {
strategy = fr.brouillard.oss.jgitver.Strategies.PATTERN
versionPattern = "\${v}-standard"
tagVersionPattern = "\${v}-tag"
}

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
jgitver {
strategy = fr.brouillard.oss.jgitver.Strategies.PATTERN
versionPattern = "\${v}-standard"
tagVersionPattern = "\${v}-tag"
}
18 changes: 0 additions & 18 deletions src/test/integration/test/base-build.gradle

This file was deleted.

10 changes: 10 additions & 0 deletions src/test/integration/test/base-build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
plugins {
id("fr.brouillard.oss.gradle.jgitver") version "0.9.1"
}

repositories {
mavenLocal()
maven {
url = uri("https://plugins.gradle.org/m2/")
}
}
6 changes: 3 additions & 3 deletions src/test/integration/test/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ if [[ $# -ne 3 ]] ; then
exit 1
fi

if [[ -f ../contexts/$1/jgitver.gradle ]] ; then
if [[ -f ../contexts/$1/jgitver.gradle.kts ]] ; then
if [[ -f ../contexts/$1/git-history.sh ]] ; then
../contexts/$1/git-history.sh
cat base-build.gradle ../contexts/$1/jgitver.gradle > build.gradle
(export JGITVER_GRADLE_VERSION=$2 && ./gradlew -b build.gradle version) | tee build.log
cat base-build.gradle.kts ../contexts/$1/jgitver.gradle.kts > build.gradle.kts
(export JGITVER_GRADLE_VERSION=$2 && ./gradlew -b build.gradle.kts version) | tee build.log
COMPUTED_VERSION=`grep Version: build.log | cut -f 2 -d ' '`
rm build.log
if [ "$COMPUTED_VERSION" != "$3" ]; then
Expand Down

0 comments on commit e6e4529

Please sign in to comment.