diff --git a/.github/workflows/blank.yml b/.github/workflows/blank.yml index deb86fa..2e933ef 100644 --- a/.github/workflows/blank.yml +++ b/.github/workflows/blank.yml @@ -23,4 +23,4 @@ jobs: distribution: 'temurin' cache: maven - name: Build with Maven - run: mvn clean install -DskipTests + run: mvn clean install -DskipTests -f samples-java diff --git a/samples-java/.gitignore b/.gitignore similarity index 95% rename from samples-java/.gitignore rename to .gitignore index a848fe7..bf4b87e 100644 --- a/samples-java/.gitignore +++ b/.gitignore @@ -7,7 +7,7 @@ # Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839 # User-specific stuff -../.idea/ +.idea/ .idea/**/workspace.xml .idea/**/tasks.xml .idea/**/usage.statistics.xml @@ -175,8 +175,8 @@ Temporary Items .history .ionide .env -../../../private/samples-java/springboot-jpa/target/springbootapp-0.0.1-SNAPSHOT.jar -../../../private/samples-java/springboot-jpa/target/springbootapp-0.0.1-SNAPSHOT.jar.original +springboot-jpa/target/springbootapp-0.0.1-SNAPSHOT.jar +springboot-jpa/target/springbootapp-0.0.1-SNAPSHOT.jar.original .jar # Support for Project snippet scope diff --git a/.idea/.gitignore b/.idea/.gitignore deleted file mode 100644 index 35410ca..0000000 --- a/.idea/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -# 默认忽略的文件 -/shelf/ -/workspace.xml -# 基于编辑器的 HTTP 客户端请求 -/httpRequests/ -# Datasource local storage ignored files -/dataSources/ -/dataSources.local.xml diff --git a/.idea/compiler.xml b/.idea/compiler.xml deleted file mode 100644 index 1e5c5ac..0000000 --- a/.idea/compiler.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/dataSources.xml b/.idea/dataSources.xml deleted file mode 100644 index 402d770..0000000 --- a/.idea/dataSources.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - mongo - true - com.dbschema.MongoJdbcDriver - mongodb+srv://cluster0.pwhm1hp.mongodb.net/ - $ProjectFileDir$ - - - \ No newline at end of file diff --git a/.idea/encodings.xml b/.idea/encodings.xml deleted file mode 100644 index 8dd5709..0000000 --- a/.idea/encodings.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml deleted file mode 100644 index 5a2f139..0000000 --- a/.idea/jarRepositories.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml deleted file mode 100644 index cb79488..0000000 --- a/.idea/misc.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/sqldialects.xml b/.idea/sqldialects.xml deleted file mode 100644 index e116b24..0000000 --- a/.idea/sqldialects.xml +++ /dev/null @@ -1,7 +0,0 @@ - - - - - - - \ No newline at end of file diff --git a/.idea/uiDesigner.xml b/.idea/uiDesigner.xml deleted file mode 100644 index 2b63946..0000000 --- a/.idea/uiDesigner.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/samples-java/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md similarity index 100% rename from samples-java/CODE_OF_CONDUCT.md rename to CODE_OF_CONDUCT.md diff --git a/samples-java/CONTRIBUTING.md b/CONTRIBUTING.md similarity index 100% rename from samples-java/CONTRIBUTING.md rename to CONTRIBUTING.md diff --git a/samples-java/LICENSE b/LICENSE similarity index 100% rename from samples-java/LICENSE rename to LICENSE diff --git a/samples-java/SECURITY.md b/SECURITY.md similarity index 100% rename from samples-java/SECURITY.md rename to SECURITY.md diff --git a/samples-java/pom.xml b/pom.xml similarity index 100% rename from samples-java/pom.xml rename to pom.xml diff --git a/samples-java/springboot-jpa/README.md b/springboot-jpa/README.md similarity index 96% rename from samples-java/springboot-jpa/README.md rename to springboot-jpa/README.md index abf528c..2b6a6c4 100644 --- a/samples-java/springboot-jpa/README.md +++ b/springboot-jpa/README.md @@ -120,7 +120,7 @@ mvn clean install -Dmaven.test.skip=true `-javaagent:path of agent jar` like this 👇. -![Edit_configurations](/Edit-configurations.png "Edit configurations") +![Edit_configurations](src/main/resources/Edit-configurations.png "Edit configurations") ## Generate testcases @@ -165,7 +165,7 @@ or by querying through the browser `http://localhost:8080/api/employees/1` Now both these API calls were captured as **editable** testcases and written to `test/e2e/keploy-tests` folder. The keploy directory would also have `mocks` folder. -![testcases](/test-cases.png "Recorded Test cases and mocks") +![testcases](src/main/resources/test-cases.png "Recorded Test cases and mocks") Now, let's see the magic! 🪄💫 @@ -173,8 +173,8 @@ Now, let's see the magic! 🪄💫 There are 2 ways to test the application with Keploy. -1. [Unit Test File](/README.md#testing-using-unit-test-file) -2. [Without Unit Test File](/README.md#testing-without-using-unit-test-file) +1. [Unit Test File](README.md#testing-using-unit-test-file) +2. [Without Unit Test File](README.md#testing-without-using-unit-test-file) ### **Testing using Unit Test File** @@ -317,7 +317,7 @@ Hibernate: select employee0_.id as id1_0_0_, employee0_.email as email2_0_0_, em 2022-08-26 14:13:19.414 INFO 11560 --- [ionShutdownHook] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown completed. ``` -![testruns](/test-runs-success.png "Recent testruns") +![testruns](src/main/resources/test-runs-success.png "Recent testruns") ## Let's add a Bug in the App @@ -345,7 +345,7 @@ You'll notice the failed test-case in the output. To deep dive the problem go to [test runs](http://localhost:6789/testruns) -![testruns](/test-runs-fail.png "Recent testruns") +![testruns](src/main/resources/test-runs-fail.png "Recent testruns") **In case of any query, refer to video below,** diff --git a/samples-java/springboot-jpa/docker-compose.yaml b/springboot-jpa/docker-compose.yaml similarity index 100% rename from samples-java/springboot-jpa/docker-compose.yaml rename to springboot-jpa/docker-compose.yaml diff --git a/samples-java/springboot-jpa/pom.xml b/springboot-jpa/pom.xml similarity index 100% rename from samples-java/springboot-jpa/pom.xml rename to springboot-jpa/pom.xml diff --git a/samples-java/springboot-jpa/src/main/java/com/example/demo/SamplesJavaApplication.java b/springboot-jpa/src/main/java/com/example/demo/SamplesJavaApplication.java similarity index 100% rename from samples-java/springboot-jpa/src/main/java/com/example/demo/SamplesJavaApplication.java rename to springboot-jpa/src/main/java/com/example/demo/SamplesJavaApplication.java diff --git a/samples-java/springboot-jpa/src/main/java/com/example/demo/controller/EmployeeController.java b/springboot-jpa/src/main/java/com/example/demo/controller/EmployeeController.java similarity index 100% rename from samples-java/springboot-jpa/src/main/java/com/example/demo/controller/EmployeeController.java rename to springboot-jpa/src/main/java/com/example/demo/controller/EmployeeController.java diff --git a/samples-java/springboot-jpa/src/main/java/com/example/demo/exception/ErrorDetails.java b/springboot-jpa/src/main/java/com/example/demo/exception/ErrorDetails.java similarity index 100% rename from samples-java/springboot-jpa/src/main/java/com/example/demo/exception/ErrorDetails.java rename to springboot-jpa/src/main/java/com/example/demo/exception/ErrorDetails.java diff --git a/samples-java/springboot-jpa/src/main/java/com/example/demo/exception/GlobalExceptionHandler.java b/springboot-jpa/src/main/java/com/example/demo/exception/GlobalExceptionHandler.java similarity index 100% rename from samples-java/springboot-jpa/src/main/java/com/example/demo/exception/GlobalExceptionHandler.java rename to springboot-jpa/src/main/java/com/example/demo/exception/GlobalExceptionHandler.java diff --git a/samples-java/springboot-jpa/src/main/java/com/example/demo/exception/ResourceNotFoundException.java b/springboot-jpa/src/main/java/com/example/demo/exception/ResourceNotFoundException.java similarity index 100% rename from samples-java/springboot-jpa/src/main/java/com/example/demo/exception/ResourceNotFoundException.java rename to springboot-jpa/src/main/java/com/example/demo/exception/ResourceNotFoundException.java diff --git a/samples-java/springboot-jpa/src/main/java/com/example/demo/model/Employee.java b/springboot-jpa/src/main/java/com/example/demo/model/Employee.java similarity index 100% rename from samples-java/springboot-jpa/src/main/java/com/example/demo/model/Employee.java rename to springboot-jpa/src/main/java/com/example/demo/model/Employee.java diff --git a/samples-java/springboot-jpa/src/main/java/com/example/demo/repository/EmployeeRepository.java b/springboot-jpa/src/main/java/com/example/demo/repository/EmployeeRepository.java similarity index 100% rename from samples-java/springboot-jpa/src/main/java/com/example/demo/repository/EmployeeRepository.java rename to springboot-jpa/src/main/java/com/example/demo/repository/EmployeeRepository.java diff --git a/samples-java/springboot-jpa/src/main/resources/Edit-configurations.png b/springboot-jpa/src/main/resources/Edit-configurations.png similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/Edit-configurations.png rename to springboot-jpa/src/main/resources/Edit-configurations.png diff --git a/samples-java/springboot-jpa/src/main/resources/Run_Configuration.png b/springboot-jpa/src/main/resources/Run_Configuration.png similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/Run_Configuration.png rename to springboot-jpa/src/main/resources/Run_Configuration.png diff --git a/samples-java/springboot-jpa/src/main/resources/Video.png b/springboot-jpa/src/main/resources/Video.png similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/Video.png rename to springboot-jpa/src/main/resources/Video.png diff --git a/samples-java/springboot-jpa/src/main/resources/application.properties b/springboot-jpa/src/main/resources/application.properties similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/application.properties rename to springboot-jpa/src/main/resources/application.properties diff --git a/samples-java/springboot-jpa/src/main/resources/data.sql b/springboot-jpa/src/main/resources/data.sql similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/data.sql rename to springboot-jpa/src/main/resources/data.sql diff --git a/samples-java/springboot-jpa/src/main/resources/test-cases.png b/springboot-jpa/src/main/resources/test-cases.png similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/test-cases.png rename to springboot-jpa/src/main/resources/test-cases.png diff --git a/samples-java/springboot-jpa/src/main/resources/test-runs-fail.png b/springboot-jpa/src/main/resources/test-runs-fail.png similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/test-runs-fail.png rename to springboot-jpa/src/main/resources/test-runs-fail.png diff --git a/samples-java/springboot-jpa/src/main/resources/test-runs-success.png b/springboot-jpa/src/main/resources/test-runs-success.png similarity index 100% rename from samples-java/springboot-jpa/src/main/resources/test-runs-success.png rename to springboot-jpa/src/main/resources/test-runs-success.png diff --git a/samples-java/springboot-jpa/src/test/e2e/keploy-tests/test-1.yaml b/springboot-jpa/src/test/e2e/keploy-tests/test-1.yaml similarity index 100% rename from samples-java/springboot-jpa/src/test/e2e/keploy-tests/test-1.yaml rename to springboot-jpa/src/test/e2e/keploy-tests/test-1.yaml diff --git a/samples-java/springboot-jpa/src/test/e2e/keploy-tests/test-2.yaml b/springboot-jpa/src/test/e2e/keploy-tests/test-2.yaml similarity index 100% rename from samples-java/springboot-jpa/src/test/e2e/keploy-tests/test-2.yaml rename to springboot-jpa/src/test/e2e/keploy-tests/test-2.yaml diff --git a/samples-java/springboot-jpa/src/test/e2e/mocks/mock-1.yaml b/springboot-jpa/src/test/e2e/mocks/mock-1.yaml similarity index 100% rename from samples-java/springboot-jpa/src/test/e2e/mocks/mock-1.yaml rename to springboot-jpa/src/test/e2e/mocks/mock-1.yaml diff --git a/samples-java/springboot-jpa/src/test/e2e/mocks/mock-2.yaml b/springboot-jpa/src/test/e2e/mocks/mock-2.yaml similarity index 100% rename from samples-java/springboot-jpa/src/test/e2e/mocks/mock-2.yaml rename to springboot-jpa/src/test/e2e/mocks/mock-2.yaml diff --git a/samples-java/springboot-jpa/src/test/java/SamplesJavaApplication_Test.java b/springboot-jpa/src/test/java/SamplesJavaApplication_Test.java similarity index 100% rename from samples-java/springboot-jpa/src/test/java/SamplesJavaApplication_Test.java rename to springboot-jpa/src/test/java/SamplesJavaApplication_Test.java diff --git a/samples-java/springboot-mongodb/README.md b/springboot-mongodb/README.md similarity index 96% rename from samples-java/springboot-mongodb/README.md rename to springboot-mongodb/README.md index 4441530..1caba90 100644 --- a/samples-java/springboot-mongodb/README.md +++ b/springboot-mongodb/README.md @@ -120,7 +120,7 @@ mvn clean install -Dmaven.test.skip=true `-javaagent:path of agent jar` like this 👇. -![Edit_configurations](/Edit-configurations.png "Edit configurations") +![Edit_configurations](src/main/resources/Edit-configurations.png "Edit configurations") ## Generate testcases @@ -165,7 +165,7 @@ or by querying through the browser `http://localhost:8080/api/employees/1` Now both these API calls were captured as **editable** testcases and written to `test/e2e/keploy-tests` folder. The keploy directory would also have `mocks` folder. -![testcases](/src/main/resources/test-cases.png "Recorded Test cases and mocks") +![testcases](src/main/resources/test-cases.png "Recorded Test cases and mocks") Now, let's see the magic! 🪄💫 @@ -173,8 +173,8 @@ Now, let's see the magic! 🪄💫 There are 2 ways to test the application with Keploy. -1. [Unit Test File](/README.md#testing-using-unit-test-file) -2. [Without Unit Test File](/README.md#testing-without-using-unit-test-file) +1. [Unit Test File](README.md#testing-using-unit-test-file) +2. [Without Unit Test File](README.md#testing-without-using-unit-test-file) ### **Testing using Unit Test File** @@ -317,7 +317,7 @@ Hibernate: select employee0_.id as id1_0_0_, employee0_.email as email2_0_0_, em 2022-08-26 14:13:19.414 INFO 11560 --- [ionShutdownHook] com.zaxxer.hikari.HikariDataSource : HikariPool-1 - Shutdown completed. ``` -![testruns](/src/main/resources/test-runs-success.png "Recent testruns") +![testruns](src/main/resources/test-runs-success.png "Recent testruns") ## Let's add a Bug in the App @@ -345,7 +345,7 @@ You'll notice the failed test-case in the output. To deep dive the problem go to [test runs](http://localhost:6789/testruns) -![testruns](/src/main/resources/test-runs-fail.png "Recent testruns") +![testruns](src/main/resources/test-runs-fail.png "Recent testruns") **In case of any query, refer to video below,** diff --git a/samples-java/springboot-mongodb/pom.xml b/springboot-mongodb/pom.xml similarity index 100% rename from samples-java/springboot-mongodb/pom.xml rename to springboot-mongodb/pom.xml diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/SamplesMongoDBApplication.java b/springboot-mongodb/src/main/java/com/example/user/SamplesMongoDBApplication.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/SamplesMongoDBApplication.java rename to springboot-mongodb/src/main/java/com/example/user/SamplesMongoDBApplication.java diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/controller/UserController.java b/springboot-mongodb/src/main/java/com/example/user/controller/UserController.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/controller/UserController.java rename to springboot-mongodb/src/main/java/com/example/user/controller/UserController.java diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/exception/ErrorDetails.java b/springboot-mongodb/src/main/java/com/example/user/exception/ErrorDetails.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/exception/ErrorDetails.java rename to springboot-mongodb/src/main/java/com/example/user/exception/ErrorDetails.java diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/exception/GlobalExceptionHandler.java b/springboot-mongodb/src/main/java/com/example/user/exception/GlobalExceptionHandler.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/exception/GlobalExceptionHandler.java rename to springboot-mongodb/src/main/java/com/example/user/exception/GlobalExceptionHandler.java diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/exception/ResourceNotFoundException.java b/springboot-mongodb/src/main/java/com/example/user/exception/ResourceNotFoundException.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/exception/ResourceNotFoundException.java rename to springboot-mongodb/src/main/java/com/example/user/exception/ResourceNotFoundException.java diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/model/User.java b/springboot-mongodb/src/main/java/com/example/user/model/User.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/model/User.java rename to springboot-mongodb/src/main/java/com/example/user/model/User.java diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/repository/UserRepository.java b/springboot-mongodb/src/main/java/com/example/user/repository/UserRepository.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/repository/UserRepository.java rename to springboot-mongodb/src/main/java/com/example/user/repository/UserRepository.java diff --git a/samples-java/springboot-mongodb/src/main/java/com/example/user/service/UserService.java b/springboot-mongodb/src/main/java/com/example/user/service/UserService.java similarity index 100% rename from samples-java/springboot-mongodb/src/main/java/com/example/user/service/UserService.java rename to springboot-mongodb/src/main/java/com/example/user/service/UserService.java diff --git a/samples-java/springboot-mongodb/src/main/resources/Edit-configurations.png b/springboot-mongodb/src/main/resources/Edit-configurations.png similarity index 100% rename from samples-java/springboot-mongodb/src/main/resources/Edit-configurations.png rename to springboot-mongodb/src/main/resources/Edit-configurations.png diff --git a/samples-java/springboot-mongodb/src/main/resources/Run_Configuration.png b/springboot-mongodb/src/main/resources/Run_Configuration.png similarity index 100% rename from samples-java/springboot-mongodb/src/main/resources/Run_Configuration.png rename to springboot-mongodb/src/main/resources/Run_Configuration.png diff --git a/samples-java/springboot-mongodb/src/main/resources/application.yaml b/springboot-mongodb/src/main/resources/application.yaml similarity index 100% rename from samples-java/springboot-mongodb/src/main/resources/application.yaml rename to springboot-mongodb/src/main/resources/application.yaml diff --git a/samples-java/springboot-mongodb/src/main/resources/data.sql b/springboot-mongodb/src/main/resources/data.sql similarity index 100% rename from samples-java/springboot-mongodb/src/main/resources/data.sql rename to springboot-mongodb/src/main/resources/data.sql diff --git a/samples-java/springboot-mongodb/src/test/e2e/keploy-tests/test-1.yaml b/springboot-mongodb/src/test/e2e/keploy-tests/test-1.yaml similarity index 100% rename from samples-java/springboot-mongodb/src/test/e2e/keploy-tests/test-1.yaml rename to springboot-mongodb/src/test/e2e/keploy-tests/test-1.yaml diff --git a/samples-java/springboot-mongodb/src/test/e2e/mocks/mock-1.yaml b/springboot-mongodb/src/test/e2e/mocks/mock-1.yaml similarity index 100% rename from samples-java/springboot-mongodb/src/test/e2e/mocks/mock-1.yaml rename to springboot-mongodb/src/test/e2e/mocks/mock-1.yaml diff --git a/samples-java/springboot-mongodb/src/test/java/SamplesMongoDBApplication_Test.java b/springboot-mongodb/src/test/java/SamplesMongoDBApplication_Test.java similarity index 100% rename from samples-java/springboot-mongodb/src/test/java/SamplesMongoDBApplication_Test.java rename to springboot-mongodb/src/test/java/SamplesMongoDBApplication_Test.java