forked from Sunbird-Knowlg/knowledge-platform-db-extensions
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue #SC-2263 refactor: CircleCI setup and main pom file
- Loading branch information
1 parent
4588aa5
commit acb8b5f
Showing
2 changed files
with
98 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
version: 2.1 | ||
executorType: machine | ||
jobs: | ||
build: | ||
docker: | ||
- image: circleci/openjdk:14-jdk-buster-node-browsers-legacy | ||
steps: | ||
- checkout | ||
- restore_cache: | ||
key: kp-db-extensions-build-cache-{{ checksum "pom.xml" }} | ||
- run: | ||
name: Run build | ||
command: | | ||
mvn clean install -DskipTests | ||
- save_cache: | ||
paths: | ||
- ~/.m2 | ||
key: kp-db-extensions-build-cache-{{ checksum "pom.xml" }} | ||
|
||
unit-tests: | ||
docker: | ||
- image: circleci/openjdk:14-jdk-buster-node-browsers-legacy | ||
- image: circleci/redis:latest | ||
parallelism: 1 | ||
steps: | ||
- checkout | ||
- restore_cache: | ||
key: kp-db-extensions-test-cache-{{ checksum "pom.xml" }} | ||
- run: | ||
name: Setup environment and run tests | ||
command: | | ||
mvn scoverage:report | ||
JAVA_REPORT_PATHS=`find /home/circleci/project -iname jacoco.xml | awk 'BEGIN { RS = "" ; FS = "\n"; OFS = ","}{$1=$1; print $0}'` | ||
mvn verify sonar:sonar -Dsonar.projectKey=project-sunbird_knowledge-platform-db-extensions -Dsonar.organization=project-sunbird -Dsonar.host.url=https://sonarcloud.io -Dsonar.coverage.jacoco.xmlReportPaths=${JAVA_REPORT_PATHS} | ||
- save_cache: | ||
paths: | ||
- ~/.m2 | ||
key: kp-db-extensions-test-cache-{{ checksum "pom.xml" }} | ||
|
||
workflows: | ||
version: 2.1 | ||
build-then-test: | ||
jobs: | ||
- build | ||
- unit-tests: | ||
requires: | ||
- build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<groupId>org.sunbird</groupId> | ||
<artifactId>knowledge-platfrom-db-extensions</artifactId> | ||
<version>1.1</version> | ||
<packaging>pom</packaging> | ||
<name>sunbird knowledge platform db extensions</name> | ||
|
||
<properties> | ||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> | ||
<version.compiler.plugin>2.3.1</version.compiler.plugin> | ||
<maven.compiler.target>1.8</maven.compiler.target> | ||
<maven.compiler.source>1.8</maven.compiler.source> | ||
</properties> | ||
|
||
<modules> | ||
<module>neo4j-extensions</module> | ||
</modules> | ||
|
||
<dependencies> | ||
</dependencies> | ||
<build> | ||
<pluginManagement> | ||
<plugins> | ||
<plugin> | ||
<artifactId>maven-assembly-plugin</artifactId> | ||
<version>2.3</version> | ||
<configuration> | ||
<descriptors> | ||
<descriptor>src/assembly/bin.xml</descriptor> | ||
</descriptors> | ||
</configuration> | ||
</plugin> | ||
|
||
<plugin> | ||
<groupId>org.apache.maven.plugins</groupId> | ||
<artifactId>maven-compiler-plugin</artifactId> | ||
<version>2.3.2</version> | ||
<configuration> | ||
<source>1.8</source> | ||
<target>1.8</target> | ||
</configuration> | ||
</plugin> | ||
</plugins> | ||
</pluginManagement> | ||
</build> | ||
|
||
</project> |