diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml new file mode 100644 index 0000000..f61f252 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -0,0 +1,46 @@ +name: Bug Report +description: Something isn't working as expected +labels: ["bug"] +body: + - type: markdown + attributes: + value: Thanks for taking the time to report a bug! + - type: textarea + id: description + attributes: + label: Description + description: What happened? + validations: + required: true + - type: textarea + id: reproduce + attributes: + label: Steps to Reproduce + description: Minimal code sample or steps that trigger the bug. + render: csharp + validations: + required: true + - type: textarea + id: expected + attributes: + label: Expected Behavior + validations: + required: true + - type: textarea + id: actual + attributes: + label: Actual Behavior + validations: + required: true + - type: input + id: version + attributes: + label: Conjecture.NET Version + placeholder: "e.g. 0.3.0" + validations: + required: true + - type: input + id: dotnet + attributes: + label: .NET Version + placeholder: "e.g. .NET 10" diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml new file mode 100644 index 0000000..c0bbdf6 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -0,0 +1,5 @@ +blank_issues_enabled: false +contact_links: + - name: Question / Discussion + url: https://github.com/kommundsen/Conjecture/discussions + about: Ask questions and discuss ideas in Discussions rather than Issues. diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml new file mode 100644 index 0000000..d1acf52 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -0,0 +1,26 @@ +name: Feature Request +description: Suggest a new strategy, API, or capability +labels: ["enhancement"] +body: + - type: textarea + id: motivation + attributes: + label: Motivation + description: What problem does this solve? What property-based testing scenario is blocked without it? + validations: + required: true + - type: textarea + id: proposal + attributes: + label: Proposed API / Behavior + description: Sketch of the desired C# API or behavior. + render: csharp + - type: textarea + id: alternatives + attributes: + label: Alternatives Considered + description: What workarounds or other approaches did you consider? + - type: markdown + attributes: + value: > + **Note:** For reference, the equivalent Hypothesis (Python) feature can be linked in the description if applicable. diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..078472e --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,13 @@ +version: 2 +updates: + - package-ecosystem: nuget + directory: /src + schedule: + interval: weekly + open-pull-requests-limit: 5 + + - package-ecosystem: github-actions + directory: / + schedule: + interval: weekly + open-pull-requests-limit: 5 diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000..27a19cf --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,16 @@ +## Description + + + +## Type of change + +- [ ] Bug fix +- [ ] New feature / strategy +- [ ] Refactor (no behavior change) +- [ ] Documentation / chore + +## Checklist + +- [ ] `dotnet test src/` passes +- [ ] New behavior is covered by tests (TDD: Red → Green → Refactor) +- [ ] Follows `.editorconfig` code style diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 0000000..0845674 --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,51 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, caste, color, religion, or sexual identity and orientation. + +We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community. + +## Our Standards + +Examples of behavior that contributes to a positive environment: + +- Demonstrating empathy and kindness toward other people +- Being respectful of differing opinions, viewpoints, and experiences +- Giving and gracefully accepting constructive feedback +- Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience +- Focusing on what is best not just for us as individuals, but for the overall community + +Examples of unacceptable behavior: + +- The use of sexualized language or imagery, and sexual attention or advances of any kind +- Trolling, insulting or derogatory comments, and personal or political attacks +- Public or private harassment +- Publishing others' private information, such as a physical or email address, without their explicit permission +- Other conduct which could reasonably be considered inappropriate in a professional setting + +## Enforcement Responsibilities + +Project maintainers are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful. + +## Scope + +This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening a private [security advisory](https://github.com/kommundsen/Conjecture/security/advisories/new) or contacting the maintainers via GitHub. All complaints will be reviewed and investigated promptly and fairly. + +## Enforcement Guidelines + +**1. Correction** — Private written warning; clarity around the violation. + +**2. Warning** — A warning with consequences for continued behavior. + +**3. Temporary Ban** — Temporary ban from community interaction. + +**4. Permanent Ban** — Permanent ban from the community. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant](https://www.contributor-covenant.org), version 2.1. diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..b89e608 --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,35 @@ +# Contributing to Conjecture.NET + +Thank you for your interest in contributing! + +## Prerequisites + +- .NET 10 SDK +- An editor with EditorConfig support + +## Build & Test + +```bash +dotnet build src/ +dotnet test src/ +dotnet test src/ --filter "FullyQualifiedName~SomeTest" +``` + +## Development Workflow + +This project uses TDD. Each feature follows **Red → Green → Refactor**: + +1. Write a failing test that describes the desired behavior. +2. Write the minimal production code to make it pass. +3. Refactor without changing observable behavior, keeping tests green. + +## Submitting Changes + +1. Fork the repository and create a branch from `main`. +2. Suggested branch prefixes: `feat/`, `fix/`, `chore/`, `docs/`. +3. Ensure all tests pass (`dotnet test src/`). +4. Open a pull request against `main` with a clear description. + +## License + +By submitting a contribution you agree that your changes will be licensed under the [Mozilla Public License 2.0](LICENSE.txt) (source code) and [MIT](LICENSE-MIT.txt) (NuGet packages), consistent with the rest of the project. diff --git a/LICENSE.txt b/LICENSE.txt index 77b9b73..6b8c0fb 100644 --- a/LICENSE.txt +++ b/LICENSE.txt @@ -373,7 +373,3 @@ Exhibit B - "Incompatible With Secondary Licenses" Notice This Source Code Form is "Incompatible With Secondary Licenses", as defined by the Mozilla Public License, v. 2.0. ---- - -Inspired by the Python Hypothesis library by David R. MacIver and contributors. -https://hypothesis.works diff --git a/README.md b/README.md index a9c3000..825fd22 100644 --- a/README.md +++ b/README.md @@ -6,16 +6,10 @@ Create a .NET port of [Hypothesis] that feels like it was built for.NET. ## Credit to the HypothesisWorks/Hypothesis Team -This project is a .NET port of [Hypothesis] for Python. The concept of this project builds on and would not be possible without the work of [David R. MacIver](https://www.drmaciver.com/) and [Zac Hatfield-Dodds](https://zhd.dev/), as well as the many other [authors](https://github.com/HypothesisWorks/hypothesis/blob/master/AUTHORS.rst) of that project. - -[Hypothesis]: https://github.com/HypothesisWorks/hypothesis - -## Installation - -``` -dotnet packages add Conjecture.NET -``` +This project is an attempt at a .NET port of [Hypothesis] for Python. The concept of this project builds on and would not be possible without the work of [David R. MacIver](https://www.drmaciver.com/) and [Zac Hatfield-Dodds](https://zhd.dev/), as well as the many other [authors](https://github.com/HypothesisWorks/hypothesis/blob/master/AUTHORS.rst) of the [Hypothesis] project. ## License -Source code: [MPL-2.0](LICENSE.txt) | NuGet packages: [MIT](LICENSE-MIT.txt) \ No newline at end of file +Source code: [MPL-2.0](LICENSE.txt) | NuGet packages: [MIT](LICENSE-MIT.txt) + +[Hypothesis]: https://github.com/HypothesisWorks/hypothesis diff --git a/SECURITY.md b/SECURITY.md new file mode 100644 index 0000000..02c6780 --- /dev/null +++ b/SECURITY.md @@ -0,0 +1,15 @@ +# Security Policy + +## Supported Versions + +Conjecture.NET is pre-1.0. No version currently receives long-term security support. + +| Version | Supported | +|---------|-----------| +| < 1.0 | Best effort only | + +## Reporting a Vulnerability + +Please **do not** open a public issue for security vulnerabilities. + +Report privately via [GitHub Security Advisories](https://github.com/kommundsen/Conjecture/security/advisories/new). You will receive a response within 7 days. If confirmed, a fix will be released as soon as practical and the advisory published after patching.