diff --git a/.github/workflows/pr-builder.yml b/.github/workflows/pr-builder.yml
index 919ec49..c561ae2 100644
--- a/.github/workflows/pr-builder.yml
+++ b/.github/workflows/pr-builder.yml
@@ -39,3 +39,11 @@ jobs:
- name: Build with Maven
run: mvn clean install -U -B
+ - name: Generate coverage report
+ run: mvn test jacoco:report
+
+ - name: Upload coverage reports to Codecov
+ uses: codecov/codecov-action@v4
+ with:
+ token: ${{ secrets.CODECOV_TOKEN }}
+ files : target/site/jacoco/jacoco.xml
diff --git a/codecov.yml b/codecov.yml
new file mode 100644
index 0000000..9571a5f
--- /dev/null
+++ b/codecov.yml
@@ -0,0 +1,16 @@
+
+codecov:
+ require_ci_to_pass: yes
+ notify:
+ wait_for_ci: yes
+coverage:
+ status:
+ project:
+ default:
+ enabled: yes
+ threshold: null
+ target: auto
+ patch:
+ default:
+ target: 80%
+ threshold: 40%
diff --git a/components/org.wso2.carbon.identity.outbound.provisioning.connector.office365/pom.xml b/components/org.wso2.carbon.identity.outbound.provisioning.connector.office365/pom.xml
index 3ca6fe5..c751ed3 100644
--- a/components/org.wso2.carbon.identity.outbound.provisioning.connector.office365/pom.xml
+++ b/components/org.wso2.carbon.identity.outbound.provisioning.connector.office365/pom.xml
@@ -73,6 +73,11 @@
commons-codec.wso2
commons-codec
+
+ org.jacoco
+ jacoco-maven-plugin
+ ${jacoco.version}
+
@@ -119,6 +124,25 @@
+
+ org.jacoco
+ jacoco-maven-plugin
+ ${jacoco.version}
+
+
+
+ prepare-agent
+
+
+
+ report
+ test
+
+ report
+
+
+
+
diff --git a/pom.xml b/pom.xml
index 26ce7d1..2eb92aa 100644
--- a/pom.xml
+++ b/pom.xml
@@ -94,6 +94,44 @@
false
+
+ org.jacoco
+ jacoco-maven-plugin
+ ${jacoco.version}
+
+
+
+ prepare-agent
+
+
+
+ report
+ test
+
+ report
+
+
+
+
+
+ org.jacoco
+ jacoco-maven-plugin
+ ${jacoco.version}
+
+
+
+ prepare-agent
+
+
+
+ report
+ test
+
+ report
+
+
+
+
@@ -149,7 +187,26 @@
-
+
+ org.jacoco
+ jacoco-maven-plugin
+ ${jacoco.version}
+
+
+
+ prepare-agent
+
+
+
+ report
+ test
+
+ report
+
+
+
+
+
@@ -209,6 +266,16 @@
commons-codec
${commons-codec.version}
+
+ org.jacoco
+ jacoco-maven-plugin
+ ${jacoco.version}
+
+
+ org.jacoco
+ jacoco-maven-plugin
+ ${jacoco.version}
+
@@ -238,6 +305,8 @@
1.2.8
1.4.0.wso2v1
[1.4.0,2.0.0)
+
+ 0.8.12