Skip to content

Commit d55170d

Browse files
Merge pull request #4 from mike-d-davydov/feature/revert-dsl
Revert new DSL changes and fix compatibility checks to make them symmetrical automatically. Also introduces GitHubActions and Git Hooks to make sure that code is in good shape when merging.
2 parents 710d9cf + ac12ac3 commit d55170d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+1917
-1456
lines changed
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: '[BUG] '
5+
labels: 'bug'
6+
assignees: ''
7+
8+
---
9+
10+
**Describe the bug**
11+
A clear and concise description of what the bug is.
12+
13+
**To Reproduce**
14+
Steps to reproduce the behavior:
15+
1. Create test parameters with '...'
16+
2. Generate combinations using '....'
17+
3. Run test with '....'
18+
4. See error
19+
20+
**Expected behavior**
21+
A clear and concise description of what you expected to happen.
22+
23+
**Actual behavior**
24+
A clear and concise description of what actually happened.
25+
26+
**Code Sample**
27+
```java
28+
// Minimal code sample that reproduces the issue
29+
TestParameter browser = new TestParameter("browser", ...);
30+
CombinationTable results = JPWise.generatePairwise(browser, ...);
31+
```
32+
33+
**Environment:**
34+
- JPWise version: [e.g. 1.0.0]
35+
- Java version: [e.g. 11.0.2]
36+
- OS: [e.g. Windows 10, Ubuntu 20.04]
37+
- Maven version: [e.g. 3.8.1]
38+
39+
**Stack Trace**
40+
If applicable, add the full stack trace here.
41+
42+
**Additional context**
43+
Add any other context about the problem here.
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
---
2+
name: Feature request
3+
about: Suggest an idea for this project
4+
title: '[FEATURE] '
5+
labels: 'enhancement'
6+
assignees: ''
7+
8+
---
9+
10+
**Is your feature request related to a problem? Please describe.**
11+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12+
13+
**Describe the solution you'd like**
14+
A clear and concise description of what you want to happen.
15+
16+
**Describe alternatives you've considered**
17+
A clear and concise description of any alternative solutions or features you've considered.
18+
19+
**Use Case**
20+
Describe the specific use case or scenario where this feature would be helpful.
21+
22+
**Example Usage**
23+
If possible, provide an example of how you would like to use this feature:
24+
25+
```java
26+
// Example of how the new feature might be used
27+
TestParameter browser = new TestParameter("browser", ...);
28+
// New feature usage here
29+
```
30+
31+
**Additional context**
32+
Add any other context, screenshots, or examples about the feature request here.
33+
34+
**Priority**
35+
- [ ] Low - Nice to have
36+
- [ ] Medium - Would improve workflow
37+
- [ ] High - Blocking current work

.github/dependabot.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
version: 2
2+
updates:
3+
# Enable version updates for Maven dependencies
4+
- package-ecosystem: "maven"
5+
directory: "/"
6+
schedule:
7+
interval: "weekly"
8+
day: "monday"
9+
time: "09:00"
10+
open-pull-requests-limit: 10
11+
reviewers:
12+
- "mikhail-davydov"
13+
assignees:
14+
- "mikhail-davydov"
15+
commit-message:
16+
prefix: "deps"
17+
include: "scope"
18+
labels:
19+
- "dependencies"
20+
- "java"
21+
22+
# Enable version updates for GitHub Actions
23+
- package-ecosystem: "github-actions"
24+
directory: "/"
25+
schedule:
26+
interval: "weekly"
27+
day: "monday"
28+
time: "09:00"
29+
open-pull-requests-limit: 5
30+
reviewers:
31+
- "mikhail-davydov"
32+
assignees:
33+
- "mikhail-davydov"
34+
commit-message:
35+
prefix: "ci"
36+
include: "scope"
37+
labels:
38+
- "dependencies"
39+
- "github-actions"

.github/pull_request_template.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Pull Request
2+
3+
## Description
4+
Brief description of the changes made in this PR.
5+
6+
## Type of Change
7+
- [ ] Bug fix (non-breaking change which fixes an issue)
8+
- [ ] New feature (non-breaking change which adds functionality)
9+
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
10+
- [ ] Documentation update
11+
- [ ] Code refactoring
12+
- [ ] Performance improvement
13+
- [ ] Test improvements
14+
15+
## Changes Made
16+
- List the main changes made
17+
- Include any new classes, methods, or significant modifications
18+
- Mention any removed functionality
19+
20+
## Testing
21+
- [ ] All existing tests pass
22+
- [ ] New tests have been added for new functionality
23+
- [ ] Manual testing has been performed
24+
- [ ] Code coverage has been maintained or improved
25+
26+
## Checklist
27+
- [ ] My code follows the project's coding standards
28+
- [ ] I have performed a self-review of my own code
29+
- [ ] I have commented my code, particularly in hard-to-understand areas
30+
- [ ] I have made corresponding changes to the documentation
31+
- [ ] My changes generate no new warnings
32+
- [ ] I have added tests that prove my fix is effective or that my feature works
33+
- [ ] New and existing unit tests pass locally with my changes
34+
35+
## Related Issues
36+
Closes #(issue number)
37+
38+
## Additional Notes
39+
Any additional information that reviewers should know about this PR.

.github/workflows/ci.yml

Lines changed: 163 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,163 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches: [ master, develop, 'feature/**' ]
6+
pull_request:
7+
branches: [ master, develop ]
8+
9+
jobs:
10+
test:
11+
name: Test on Java ${{ matrix.java }}
12+
runs-on: ubuntu-latest
13+
strategy:
14+
matrix:
15+
java: [11, 17]
16+
fail-fast: false
17+
18+
steps:
19+
- name: Checkout code
20+
uses: actions/checkout@v4
21+
22+
- name: Set up JDK ${{ matrix.java }}
23+
uses: actions/setup-java@v4
24+
with:
25+
java-version: ${{ matrix.java }}
26+
distribution: 'temurin'
27+
28+
- name: Cache Maven dependencies
29+
uses: actions/cache@v4
30+
with:
31+
path: ~/.m2
32+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
33+
restore-keys: ${{ runner.os }}-m2
34+
35+
- name: Run tests
36+
run: mvn clean test
37+
38+
- name: Publish Test Results
39+
uses: EnricoMi/publish-unit-test-result-action@v2
40+
if: always()
41+
with:
42+
files: |
43+
target/surefire-reports/junitreports/TEST-*.xml
44+
check_name: "Test Results (Java ${{ matrix.java }})"
45+
46+
- name: Upload test results
47+
uses: actions/upload-artifact@v4
48+
if: always()
49+
with:
50+
name: test-results-java${{ matrix.java }}
51+
path: target/surefire-reports/
52+
53+
code-quality:
54+
name: Code Quality Checks
55+
runs-on: ubuntu-latest
56+
57+
steps:
58+
- name: Checkout code
59+
uses: actions/checkout@v4
60+
61+
- name: Set up JDK 11
62+
uses: actions/setup-java@v4
63+
with:
64+
java-version: 11
65+
distribution: 'temurin'
66+
67+
- name: Cache Maven dependencies
68+
uses: actions/cache@v4
69+
with:
70+
path: ~/.m2
71+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
72+
restore-keys: ${{ runner.os }}-m2
73+
74+
- name: Run SpotBugs Analysis
75+
run: |
76+
echo "🔍 Starting SpotBugs analysis..."
77+
echo "Java version:"
78+
java -version
79+
echo "Maven version:"
80+
mvn -version
81+
echo "Current directory: $(pwd)"
82+
echo "Files in target directory:"
83+
ls -la target/ || echo "Target directory doesn't exist yet"
84+
85+
echo "🏗️ Compiling project first..."
86+
mvn clean compile -X
87+
88+
echo "🔍 Running SpotBugs analysis with verbose output..."
89+
mvn spotbugs:spotbugs -X
90+
91+
echo "📁 Checking generated files..."
92+
ls -la target/ || echo "Target directory still doesn't exist"
93+
94+
echo "🔍 Running critical issues check..."
95+
chmod +x scripts/spotbugs-critical-check.sh
96+
./scripts/spotbugs-critical-check.sh
97+
98+
- name: Upload SpotBugs Report
99+
uses: actions/upload-artifact@v4
100+
if: always()
101+
with:
102+
name: spotbugs-report
103+
path: |
104+
target/spotbugsXml.xml
105+
target/spotbugs.html
106+
107+
108+
109+
- name: Run Checkstyle
110+
run: |
111+
mvn checkstyle:check
112+
if [ $? -ne 0 ]; then
113+
echo "❌ Code style issues found. Please fix them according to Checkstyle rules."
114+
exit 1
115+
else
116+
echo "✅ Code style is correct."
117+
fi
118+
119+
- name: Compile and package
120+
run: mvn clean compile package -DskipTests
121+
122+
- name: Upload build artifacts
123+
uses: actions/upload-artifact@v4
124+
with:
125+
name: build-artifacts
126+
path: target/*.jar
127+
128+
coverage:
129+
name: Code Coverage
130+
runs-on: ubuntu-latest
131+
132+
steps:
133+
- name: Checkout code
134+
uses: actions/checkout@v4
135+
136+
- name: Set up JDK 11
137+
uses: actions/setup-java@v4
138+
with:
139+
java-version: 11
140+
distribution: 'temurin'
141+
142+
- name: Cache Maven dependencies
143+
uses: actions/cache@v4
144+
with:
145+
path: ~/.m2
146+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
147+
restore-keys: ${{ runner.os }}-m2
148+
149+
- name: Run tests with coverage
150+
run: mvn clean test jacoco:report
151+
152+
- name: Upload coverage to Codecov
153+
uses: codecov/codecov-action@v4
154+
with:
155+
file: target/site/jacoco/jacoco.xml
156+
flags: unittests
157+
name: codecov-umbrella
158+
159+
- name: Upload coverage reports
160+
uses: actions/upload-artifact@v4
161+
with:
162+
name: coverage-reports
163+
path: target/site/jacoco/

0 commit comments

Comments
 (0)