Generated assertions do not preserve generic types
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 35/100
Research direction
Start by reproducing the issue with a field declared as Optional and inspect the generator path that derives assertion method parameters from field types. Done means the generated hasFoo parameter preserves the generic type, producing Optional rather than raw Optional; add or update coverage for this example if the project has a relevant generator test.
Written by the indexing model from the issue text.
Description
For example, if I have:
public final Optional<Boolean> foo;,
the generated assertion is:
hasFoo(java.util.Optional foo)
when it should be:
hasFoo(java.util.Optional<Boolean> foo)
- Dominant language
- Java
- Stars
- 72
- Forks
- 47
- PR merge metrics
- No merged PRs in 30d
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.
More from assertj/assertj-generator
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
assertj/assertj-generator#278 ·
-
Difficulty 5/5 Over a week Newbie friendliness 30/100
assertj/assertj-generator#220 ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
assertj/assertj-generator#219 ·
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
assertj/assertj-generator#204 · 1 reaction ·
-
Difficulty 4/5 3-5 days Newbie friendliness 35/100
assertj/assertj-generator#197 · 7 comments ·
All issues in assertj/assertj-generator
Similar issues
-
bug
Difficulty 1/5 Under an hour Newbie friendliness 90/100
apache/cloudstack#14222 ·
-
[BUG]茶杯方块在取茶时会引发崩溃 Open
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
1.0.0-alpha2 Type/Improvement
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
wso2/dpdp-accelerator#272 ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
apache/rocketmq-dashboard#4860 · 1 comment ·
-
agent-audit bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
Vault-Web/cloud-page#144 ·