alibaba / tamper

A Java Bean to Java Bean mapper that recursively copies data from one object to another
http://github.com/alibaba/tamper
Apache License 2.0
247 stars 113 forks source link

fix flaky test in CollectionAndCollectionTest.java #18

Closed Kerr0220 closed 1 year ago

Kerr0220 commented 2 years ago

Hi! I'm a graduate student at UIUC. We are working on a project NonDex to find out flaky tests in open source projects and help developers to fix them.

The flaky test can be caused by the feature of HashMap or HashSet that when you iterate it, the order is non-deterministic. Therefore, sometimes the test passes while sometimes it fails.

We have found 2 flaky tests in your project and com.alibaba.tamper.convertor.CollectionAndCollectionTest is one of them.

The flakiness in this test was caused by the non-deterministic feature of HashSet. Therefore, I changed it to LinkedHashSet which is iterated in a deterministic order. And now the test is un-flaky!

Please feel free to ask me any questions about the flaky test! We are working on it. And hope this PR can be accepted!

CLAassistant commented 2 years ago

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


yiteng3 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant commented 2 years ago

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


yiteng3 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

Kerr0220 commented 2 years ago

I added my email address to this account, agreed with the license, and clicked the recheck button, but nothing happened. Is there anything wrong?