Skip to content

Commit

Permalink
New test is targetting the StaticCallToNonStaticTest()
Browse files Browse the repository at this point in the history
  • Loading branch information
sanidhya00081 committed Jan 27, 2025
1 parent 892a4c7 commit b758439
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/simple_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@ jobs:
- name: Run PolDet test
run: ./gradlew testPolDet
- name: Test on modified class file
run: ./gradlew runModifiedTest
run: ./gradlew runModifiedTest --info
10 changes: 7 additions & 3 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -110,11 +110,15 @@ tasks.named('compilePeersJava') {
dependsOn(copyResources)
}
task runModifiedTest(type: Test) {
description = "Runs the test for the modified class file."
group = "verification"
description = 'Run modified test'
group = 'verification'
testClassesDirs = sourceSets.test.output.classesDirs
classpath = sourceSets.test.runtimeClasspath
include '**/StaticCallToNonStaticTest.class'

useJUnitPlatform()
include "**/StaticCallToNonStaticTest.class" // Runs only the new test class
}

tasks.named("runModifiedTest") {
dependsOn("compileTestJava")
shouldRunAfter("test")
Expand Down
2 changes: 1 addition & 1 deletion src/tests/gov/nasa/jpf/StaticCallToNonStaticTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
public class StaticCallToNonStaticTest extends TestJPF {

@Test
public void testStaticCallToNonStatic() {
public void testStaticCallToNonStatic() {
D.m();
}

Expand Down

0 comments on commit b758439

Please sign in to comment.