question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Help fix broken / ignored unit tests or other analytics!

See original GitHub issue

After merging #3856 one unit test class, TypeRegistryTest, intermittently stalled during local testing. It may be fine on some OSes or in Jenkins, but oddly it stalled even with the @Ignored annotation added to the tests. It would be good if a few different people to re-enable those tests and run them locally several times (one at a time, all three at once, etc) and make sure they don’t stall - if not then we can re-enable and I’ll just blame my workspace.

Additionally at present we skip 7 tests in EntityAwareWorldProviderTest and another 7 in ParallelTest for reasons of the past I don’t remember off the top of my head, but the files and Git / GitHub history may help shed some background info on that topic.

Finally there are two tests in the ModuleTestingEnvironment that are getting stuck in infinite loops for me testing locally in LocalChunkProvider.checkForUnload() - not sure that’d relate to these changes. ClientConnectionTest and ExampleTest

Beyond unit tests there are plenty of other code analytics that result in issues, although the stats are still only published in our new Jenkins which isn’t exposed publicly yet, although regular contributors can request access any time for some insight. In the meantime you can run gradlew check locally and find an abundance of warnings 😃

In Jenkins specifically unit tests tend to fail if they involve a game environment, #3415 has the details and it would be a lovely thing to fix as well.

Marking Good First Issue as these topics are all mildly unrelated to anything else and decent detective hunts for curious contributors, even if they aren’t necessarily going to be easy!

Edit: there is also a weird issue where SpotBugs works for some modules but not others, resulting in no build/reports/spotbugs directory. I saw an error related to it at one point, but forgot where. It showed both locally and in Jenkins so it shouldn’t be hard to replicate if looking across a few modules. Pretty sure Pathfinding had the failure. Could run gradlew spotbugsMain to selectively just run SpotBugs in a workspace then go looking for which modules made that build dir or not.

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
Cervatorcommented, Apr 26, 2020

Hi @lizzyd710! … well, we have some! 😁

But 700+ tests barely make a dent in the engine project here when it comes to percentage coverage, then there are oodles of modules and other side projects. We’re always low on tests - any assistance writing more would be really appreciated!

0reactions
jdrueckertcommented, Jan 11, 2022

@pree-T Generally yes. It does need a decent bit of investigation first, though. But sure, go ahead, give it a try and ideally first drop your findings about broken or ignored tests in here before starting to try to fix them 😉

Read more comments on GitHub >

github_iconTop Results From Across the Web

Are Your Unit Tests Failing and You Don't Know Why? - Parasoft
To do so, it's important to understand what it means when a unit test fails. It boils down to three reasons, with simple...
Read more >
Broken Old/Legacy Unit Tests
What I would do is first disable the tests which are failing-and-have-always-failed. Make it so a test failing matters. As you investigate you...
Read more >
Troubleshooting Code Coverage - Visual Studio (Windows)
Learn how to resolve erroneous empty results messages when you expect Visual Studio to collect data for native and managed assemblies.
Read more >
Keys to Successful Unit Testing - Software Testing Help
I'm a developer, and I need to know the correct/exact sequence of, analysis, estimation, design documentation, unit test cases writing, ...
Read more >
Unit Testing Best Practices: 9 to Ensure You Do It Right
By frequently running the tests, they can assure their recent modifications to the code haven't broken anything. In other words, unit tests help...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found