From 2b7fc651f8b818eb871084dda0c1d89f7a9efa06 Mon Sep 17 00:00:00 2001
From: Carl Jones <jonesc162@cardiff.ac.uk>
Date: Tue, 4 Jul 2023 12:22:36 +0100
Subject: [PATCH] test pitest on CI

---
 .idea/compiler.xml                            |  3 ++
 ...ssessment-1-2022-starter-wormhole.test.iml |  3 ++
 build.gradle                                  | 29 ++++++++++---------
 gradle/wrapper/gradle-wrapper.properties      |  2 +-
 .../cm6123/monopoly/game/package-info.java    |  2 +-
 5 files changed, 24 insertions(+), 15 deletions(-)

diff --git a/.idea/compiler.xml b/.idea/compiler.xml
index b589d56..bcb93c4 100644
--- a/.idea/compiler.xml
+++ b/.idea/compiler.xml
@@ -1,6 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <project version="4">
   <component name="CompilerConfiguration">
+    <annotationProcessing>
+      <profile default="true" name="Default" enabled="true" />
+    </annotationProcessing>
     <bytecodeTargetLevel target="17" />
   </component>
 </project>
\ No newline at end of file
diff --git a/.idea/modules/assessment-1-2022-starter-wormhole.test.iml b/.idea/modules/assessment-1-2022-starter-wormhole.test.iml
index b9ac931..3ca7fa1 100644
--- a/.idea/modules/assessment-1-2022-starter-wormhole.test.iml
+++ b/.idea/modules/assessment-1-2022-starter-wormhole.test.iml
@@ -1,5 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <module version="4">
+  <component name="CheckStyle-IDEA-Module" serialisationVersion="2">
+    <option name="activeLocationsIds" />
+  </component>
   <component name="NewModuleRootManager" inherit-compiler-output="true">
     <exclude-output />
     <orderEntry type="sourceFolder" forTests="false" />
diff --git a/build.gradle b/build.gradle
index d379caa..75bde12 100644
--- a/build.gradle
+++ b/build.gradle
@@ -15,6 +15,7 @@ group 'com.nsa.cm6123-6623'
 version '1.0-SNAPSHOT'
 
 sourceCompatibility = 17
+targetCompatibility = 17
 
 repositories {
     mavenCentral()
@@ -22,15 +23,15 @@ repositories {
 
 dependencies {
 
-    implementation 'org.apache.logging.log4j:log4j-api:2.17.1'
-    implementation 'org.apache.logging.log4j:log4j-core:2.17.1'
-    implementation 'org.apache.logging.log4j:log4j-slf4j-impl:2.17.1'
+    implementation 'org.apache.logging.log4j:log4j-api:2.20.0'
+    implementation 'org.apache.logging.log4j:log4j-core:2.20.0'
+    implementation 'org.apache.logging.log4j:log4j-slf4j-impl:2.20.0'
 
 
-    testImplementation(platform('org.junit:junit-bom:5.7.0'))
-    testImplementation('org.junit.jupiter:junit-jupiter:5.8.2')
-    testImplementation('org.mockito:mockito-core:4.1.0')
-    testImplementation("org.junit.jupiter:junit-jupiter-params:5.8.2")
+    testImplementation(platform('org.junit:junit-bom:5.9.2'))
+    testImplementation('org.junit.jupiter:junit-jupiter:5.9.2')
+    testImplementation('org.mockito:mockito-core:5.2.0')
+    testImplementation("org.junit.jupiter:junit-jupiter-params:5.9.2")
 
 }
 
@@ -78,9 +79,11 @@ checkstyleMain {
 
 jacocoTestReport {
     reports {
-        xml.enabled false
-        csv.enabled false
-        html.destination file("${buildDir}/jacocoHtml")
+        xml.required = false
+        csv.required = false
+        html.outputLocation = layout.buildDirectory.dir('jacocoHtml')
+
+        //html.destination file("${buildDir}/jacocoHtml")
     }
 }
 jacocoTestCoverageVerification {
@@ -110,12 +113,12 @@ rootProject.tasks.named("jar") {
 }
 
 pitest {
-    targetClasses = ['com.cm6123.monopoly.game.*']  //by default "${project.group}.*"
-    //pitestVersion = '1.9.0' //not needed when a default PIT version should be used
+    targetClasses = ['com.cm6123.monopoly.*']  //by default "${project.group}.*"
+    pitestVersion = '1.14.2' //not needed when a default PIT version should be used
     threads = 4
     outputFormats = ['XML', 'HTML']
     timestampedReports = false
-    junit5PluginVersion = '1.0.0'
+    junit5PluginVersion = '1.2.0'
 
     reportAggregator {
         testStrengthThreshold.set(50)
diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties
index aa991fc..15de902 100644
--- a/gradle/wrapper/gradle-wrapper.properties
+++ b/gradle/wrapper/gradle-wrapper.properties
@@ -1,5 +1,5 @@
 distributionBase=GRADLE_USER_HOME
 distributionPath=wrapper/dists
-distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip
+distributionUrl=https\://services.gradle.org/distributions/gradle-8.2-bin.zip
 zipStoreBase=GRADLE_USER_HOME
 zipStorePath=wrapper/dists
diff --git a/src/main/java/com/cm6123/monopoly/game/package-info.java b/src/main/java/com/cm6123/monopoly/game/package-info.java
index e6fba2e..934351c 100644
--- a/src/main/java/com/cm6123/monopoly/game/package-info.java
+++ b/src/main/java/com/cm6123/monopoly/game/package-info.java
@@ -3,4 +3,4 @@
  * This is the package root that should be subjected to automated testing.
  * It should not have any user interface code in it.
  */
-package com.cm6123.monopoly.game;
\ No newline at end of file
+package com.cm6123.monopoly.game;
-- 
GitLab