Skip to content

Commit

Permalink
Merge branch 'TNG:master' into 54-asciiDocReporter-documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
johthor authored Nov 23, 2023
2 parents ea064a7 + a91e84c commit 4695517
Show file tree
Hide file tree
Showing 77 changed files with 706 additions and 377 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/gradle-wrapper-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@ jobs:
name: "Validation"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.5.3
- uses: gradle/wrapper-validation-action@v1.0.6
- uses: actions/checkout@v4.1.1
- uses: gradle/wrapper-validation-action@v1.1.0
2 changes: 1 addition & 1 deletion .github/workflows/jgiven_align_gh_pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
name: Rebase gh-pages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.5.3
- uses: actions/checkout@v4.1.1
with:
fetch-depth: '0' #fetch all history
ref: 'gh-pages'
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/jgiven_android_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ jobs:
env:
ANDROID: true
steps:
- uses: actions/checkout@v3.5.3
- uses: actions/checkout@v4.1.1
- name: Set upt JDK 17
uses: actions/setup-java@v3.11.0
uses: actions/setup-java@v3.13.0
with:
java-version: 17
distribution: 'adopt'
Expand All @@ -26,7 +26,7 @@ jobs:
- name: Upload test results html files
continue-on-error: true
if: ${{failure()}}
uses: actions/[email protected].2
uses: actions/[email protected].3
with:
name: test-report-example-projects
path: /home/runner/work/JGiven/JGiven/example-projects/*/build/reports/tests
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/jgiven_branch_and_pr_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ jobs:
steps:
- name: Ensure firefox is installed
run: sudo apt-get install firefox
- uses: actions/checkout@v3.5.3
- uses: actions/checkout@v4.1.1
- name: Set up JDK ${{matrix.java}}
uses: actions/setup-java@v3.11.0
uses: actions/setup-java@v3.13.0
with:
java-version: ${{matrix.java}}
distribution: 'adopt'
Expand All @@ -32,7 +32,7 @@ jobs:
- name: Upload test results html files
continue-on-error: true
if: ${{failure()}}
uses: actions/[email protected].2
uses: actions/[email protected].3
with:
name: test-report_${{matrix.java}}_${{matrix.junit}}
path: /home/runner/work/JGiven/JGiven/*/build/reports/tests
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/jgiven_examples_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,14 @@ jobs:
name: Test that the examples are actually working
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.5.3
- uses: actions/checkout@v4.1.1
- name: Set up JDK 17
uses: actions/setup-java@v3.11.0
uses: actions/setup-java@v3.13.0
with:
java-version: '17'
distribution: 'adopt'
- name: Setup Android SDK
uses: android-actions/setup-android@v2.0.10
uses: android-actions/setup-android@v3.1.0
- name: Produce a local release with version 1.1-t
run: source scripts/local_release_with_version.sh
- name: Test Kotlin Example Project
Expand Down Expand Up @@ -44,7 +44,7 @@ jobs:
- name: Upload test results html files
continue-on-error: true
if: ${{failure()}}
uses: actions/[email protected].2
uses: actions/[email protected].3
with:
name: test-report-example-projects
path: /home/runner/work/JGiven/JGiven/example-projects/*/build/reports/tests
Expand All @@ -61,7 +61,7 @@ jobs:
- name: Upload test results html files
continue-on-error: true
if: ${{failure()}}
uses: actions/[email protected].2
uses: actions/[email protected].3
with:
name: test-report-example-projects
path: /home/runner/work/JGiven/JGiven/example-projects/*/build/reports/tests
Expand All @@ -70,7 +70,7 @@ jobs:
name: Validate the format of the published poms
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.5.3
- uses: actions/checkout@v4.1.1
- name: Load the bash script
run: scripts/local_release_with_version.sh
- name: Run validation
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/run_renovate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3.5.3
uses: actions/checkout@v4.1.1
- name: Renovate-dry-run
uses: renovatebot/github-action@v39.0.0
uses: renovatebot/github-action@v39.1.3
with:
configurationFile: renovate.json
token: ${{secrets.RENOVATE_TOKEN}}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test-bash-functions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ jobs:
name: "validate release functions"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.5.3
- uses: actions/checkout@v4.1.1
- name: Run release functions test
run: "bash scripts/tests/test_release_functions.sh"
validateHelperFunctions:
name: "validate helper functions"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3.5.3
- uses: actions/checkout@v4.1.1
- name: Run helper functions test
run: "bash scripts/tests/test_helper_functions.sh"
26 changes: 16 additions & 10 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,34 @@
# v1.3
# Release v1.3.1
* TextReportGenerator is now backed by jansi2 not jansi1. [#1420](https://github.com/TNG/JGiven/issues/1420)
* Further dependency updates.
# Release v1.3.0
## Breaking changes
* Increased minimum supported version to Java 11

## Fixed issues
* Escaped dollars ($$) are now treated as a regular $ character.[#1253](https://github.com/TNG/JGiven/issues/1253) (thanks to manoj-fd for reporting)
* Escaped dollars ($$) are now treated as a regular $ character.[#1253](https://github.com/TNG/JGiven/issues/1253) (thanks to manoj-fd for reporting)
* Contribution guidelines are now up to date [#1300](https://github.com/TNG/JGiven/issues/1300)(thanks to johthor for reporting)
## Honorable mentions
* Thanks to johthor for starting (and completing to a large degree) the implementation of an asciidoc reporter [#54](https://github.com/TNG/JGiven/issues/54)

# v1.2.5
# Release v1.2.5
## Fixed issues
* Fixed incompatibility of Gradle plugin with Gradle 8, due to the use of a deprecated method [#1200](https://github.com/TNG/JGiven/issues/1200) (thanks to AistisTaraskevicius for reporting)

# v1.2.4
# Release v1.2.4
## Fixed issues
* Fixed incorrect POM that was published because our manual pom transcription writes a version tag even when none is required. [#1013](https://github.com/TNG/JGiven/issues/1013) (thanks to jangalanski for reporting)

# v1.2.3
# Release v1.2.3
## Fixed issues
* Fixed build error when JGiven is used in conjuntion with openapi. [#947](https://github.com/TNG/JGiven/issues/947) (thanks to manoj-fd for reporting)
* Improved robustness of the html-apps zip file processing. [#929] (https://github.com/TNG/JGiven/pull/929) (thanks to JLLeitschuh)

# v1.2.2
# Release v1.2.2
## Fixed issues
* Fixed issue where tags listed all of their ancestors as direct parents [#868](https://github.com/TNG/JGiven/issues/868) (thanks to jadhindieh for reporting)

# v1.2.1
# Release v1.2.1
## New features
* JGiven-JUnit5 now reports its test outcomes back to JUnit5 before the `@After` methods, not after them. This should make it easier to run extensions like ReportPortal alongside JUnit5.
## Fixed issues
Expand All @@ -36,13 +42,13 @@
## Backward incompatible changes
* Removed explicit support for PowerMock in JGiven-JUnit4 package, because the powermock project appears to be abandoned.

# v1.2
# Release v1.2
## New features
* JGiven now supports Spock 2 [#784](https://github.com/TNG/JGiven/pull/784) (thanks to jsalinaspolo)
## Fixed issues
* JGiven now records step timings correctly if there are intro or filler words in a step [#755](https://github.com/TNG/JGiven/issues/755)

# v1.1
# Release v1.1
## New features
* The lifecycle method annotations `@BeforeStage` and `@AfterStage` have an option to make the associated methods be invoked repeatedly if the stage class is invoked multiple times. Note that the duration of a stage is denoted by the change of the stage class, thus multiple invocations (no matter the form) on the same stage class count as one stage.
* The field annotations `@ScenarioState` and `@ProvidedScenarioState` can be set to be `guaranteed`. This ensures that the stage that is declaring such field must operate on it during execution and after the stage finishes the field is ensured to be initialized.
Expand All @@ -60,7 +66,7 @@
* JGiven-Spring does not export its dependency on JGiven-Core anymore, because JGiven-Spring should be used with
of the test packages JGiven-JUnit, JGiven-Spock, JGiven-JUnit5, JGiven-TestNG, where that dependency is exported

# v1.0.0
# Release v1.0.0

This is the first major version update of JGiven. It does introduce new features, as well as backwards-incompatible changes,
due to the removal of all deprecated classes and methods and the drop of Java 7 support.
Expand Down
19 changes: 10 additions & 9 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ plugins {
id 'com.github.kt3k.coveralls' version '2.12.2'
id 'org.asciidoctor.jvm.convert' version '3.3.2'
id 'io.codearte.nexus-staging' version '0.30.0'
id 'com.github.ben-manes.versions' version '0.47.0'
id 'org.sonarqube' version '4.3.0.3225' apply false
id 'com.github.node-gradle.node' version '5.0.0' apply false
id 'com.github.ben-manes.versions' version '0.50.0'
id 'org.sonarqube' version '4.4.1.3373' apply false
id 'com.github.node-gradle.node' version '7.0.1' apply false
}


Expand Down Expand Up @@ -77,13 +77,13 @@ subprojects {
}
withXml {
project.configurations.compileOnly.allDependencies.each { dep ->
asNode().dependencies[0].appendNode('dependency').with {
it.appendNode('groupId', dep.group)
it.appendNode('artifactId', dep.name)
asNode().dependencies[0].appendNode('dependency').with { dependencyNode ->
dependencyNode.appendNode('groupId', dep.group)
dependencyNode.appendNode('artifactId', dep.name)
if (dep.version != null && dep.version.trim() != "") {
it.appendNode('version', dep.version)
dependencyNode.appendNode('version', dep.version)
}
it.appendNode('scope', 'provided')
dependencyNode.appendNode('scope', 'provided')
}
}

Expand Down Expand Up @@ -283,7 +283,7 @@ configure(subprojects) {
}

checkstyle {
toolVersion = "10.12.1"
toolVersion = "10.12.5"
configFile = file("${rootProject.projectDir}/checkstyle.xml")
showViolations = false
ignoreFailures = true
Expand All @@ -292,6 +292,7 @@ configure(subprojects) {
// -- build and publish artifacts -------------------------------------------------------------------------------------

signing {

// requires gradle.properties, see http://www.gradle.org/docs/current/userguide/signing_plugin.html
required {
isReleaseVersion && gradle.taskGraph.getAllTasks().any { it instanceof PublishToMavenRepository }
Expand Down
12 changes: 9 additions & 3 deletions example-projects/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -46,19 +46,25 @@ configurations {
}

dependencies {
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation('androidx.appcompat:appcompat:1.6.1') {
exclude group: 'com.google.guava', module: 'listenablefuture'
}

androidTestImplementation('androidx.test.espresso:espresso-core:3.5.1', {
exclude group: 'com.android.support', module: 'support-annotations'
exclude group: 'com.google.guava', module: 'listenablefuture'

})
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation('androidx.test.ext:junit:1.1.5') {
exclude group: 'com.google.guava', module: 'listenablefuture'
}
androidTestImplementation('androidx.test:rules:1.5.0') {
exclude group: "junit"
}
androidTestImplementation('com.tngtech.jgiven:jgiven-android:' + version)

jgivenReport 'com.tngtech.jgiven:jgiven-html5-report:' + version
jgivenReport 'org.slf4j:slf4j-simple:2.0.7'
jgivenReport 'org.slf4j:slf4j-simple:2.0.9'
}

def targetDir = 'build/reports/jgiven/json'
Expand Down
2 changes: 1 addition & 1 deletion example-projects/android/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
version=1.2.5
version=1.3.0
org.gradle.jvmargs=-Xmx1536M
org.gradle.parallel=true
android.useAndroidX=true
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
4 changes: 2 additions & 2 deletions example-projects/java11/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<version>0.0.1-SNAPSHOT</version>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jgiven.version>1.2.5</jgiven.version>
<jgiven.version>1.3.0</jgiven.version>
</properties>
<dependencies>
<dependency>
Expand Down Expand Up @@ -36,7 +36,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.1.2</version>
<version>3.2.2</version>
<configuration>
<systemPropertyVariables>
<jgiven.report.text.color>true</jgiven.report.text.color>
Expand Down
4 changes: 2 additions & 2 deletions example-projects/junit5/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ repositories {

dependencies {
testImplementation "com.tngtech.jgiven:jgiven-junit5:${jgivenVersion}"
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.3'
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.9.3'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.1'
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.10.1'
}

test {
Expand Down
2 changes: 1 addition & 1 deletion example-projects/junit5/gradle.properties
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
version=1.2.5
version=1.3.0
org.gradle.jvmargs=-Xmx1536M
org.gradle.parallel=true
Binary file modified example-projects/junit5/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.2.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
17 changes: 9 additions & 8 deletions example-projects/junit5/gradlew
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ done
# This is normally unused
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
Expand Down Expand Up @@ -144,15 +145,15 @@ if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then
case $MAX_FD in #(
max*)
# In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045
# shellcheck disable=SC2039,SC3045
MAX_FD=$( ulimit -H -n ) ||
warn "Could not query maximum file descriptor limit"
esac
case $MAX_FD in #(
'' | soft) :;; #(
*)
# In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked.
# shellcheck disable=SC3045
# shellcheck disable=SC2039,SC3045
ulimit -n "$MAX_FD" ||
warn "Could not set maximum file descriptor limit to $MAX_FD"
esac
Expand Down Expand Up @@ -201,11 +202,11 @@ fi
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'

# Collect all arguments for the java command;
# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of
# shell script including quotes and variable substitutions, so put them in
# double quotes to make sure that they get re-expanded; and
# * put everything else in single quotes, so that it's not re-expanded.
# Collect all arguments for the java command:
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# and any embedded shellness will be escaped.
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
# treated as '${Hostname}' itself on the command line.

set -- \
"-Dorg.gradle.appname=$APP_BASE_NAME" \
Expand Down
6 changes: 3 additions & 3 deletions example-projects/kotlin/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ buildscript {
}

plugins {
id "org.jetbrains.kotlin.jvm" version "1.9.0"
id "org.jetbrains.kotlin.jvm" version "1.9.20"
}

apply plugin: 'java'
Expand All @@ -36,8 +36,8 @@ repositories {
dependencies {
testImplementation 'com.tngtech.jgiven:jgiven-junit5:' + jgivenVersion
testImplementation 'org.jetbrains.kotlin:kotlin-stdlib-jdk8'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.9.3'
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.9.3'
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.10.1'
testImplementation 'org.junit.jupiter:junit-jupiter-engine:5.10.1'
}

test {
Expand Down
2 changes: 1 addition & 1 deletion example-projects/kotlin/gradle.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
version=1.2.5
version=1.3.0
Binary file modified example-projects/kotlin/gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
Loading

0 comments on commit 4695517

Please sign in to comment.