a suggestion for `minSize` operator enhancement
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 699
- Forks
- 124
- Avg merge
- 24m
- Merged PRs (30d)
- 7
Description
Describe the feature you request
When setting a collection with fixture monkey operator minSize, then I expect it to be NOT null.
For example, it would be nice to have tearchers which is always NOT null in the below circumstance. The rational behind this is that if the size of a collection is greater than 0, the collection should not be null.
fun school(fixture: FixtureMonkey): ArbitraryBuilder<School> =
fixture.giveMeBuilder(School::class.java)
.minSize("teachers", 1)
data class School() {
val teachers: List<Teacher>
}
If the feature request is approved, would you be willing to submit a PR?
Yes
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the Fixture Monkey minSize operator and trace how it applies constraints to collection properties. Use the School example with minSize("teachers", 1) to verify the resulting teachers collection is both non-null and has at least one element; done means this behavior is covered by tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- kotlin
- Domain
- testing-qa
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100