Thank you for your interest in contributing to Pure Assert! This document provides guidelines and instructions for contributing.
Be respectful and constructive in all interactions. We welcome contributors of all experience levels.
- Check if the issue already exists in the Issues section.
- If not, create a new issue with:
- A clear title
- Steps to reproduce
- Expected vs. actual behavior
- Java version and environment details
Open an issue with the enhancement label. Describe:
- The use case
- The proposed API (if applicable)
- Why it fits this library's philosophy
- Fork the repository and create a branch from
main. - Write tests for any new functionality.
- Follow the code style: no external dependencies, comprehensive Javadoc.
- Run the build:
mvn clean verify - Submit your PR with a clear description.
- Java 15+
- Maven 3.8+
mvn clean installmvn testmvn javadoc:javadocThis library is intentionally zero-dependency. Do not add any runtime dependencies. The maven-enforcer-plugin will reject any transitive dependencies.
All public classes and methods must have Javadoc comments. Run mvn javadoc:javadoc to check for warnings.
When adding new exceptions:
- Extend
AssertionException - Implement
type()returning an appropriateAssertionErrorType - Use a builder pattern for complex exceptions
- Include the field name and relevant metadata
When adding new asserters (e.g., StringAsserter):
- Follow the fluent API pattern
- Return
thisfor chaining - Include a
value()method to retrieve the validated value - Throw specific exceptions, not generic ones
Feel free to open an issue for any questions about contributing.
Thank you for helping make Pure Assert better! 🚀