Write RigidBody / Physics Unit Tests
See original GitHub issueSummary
There are already unit tests that check some basic cloning / copying functionality, but there are none that test actual physics and transformation behavior. Add a few basic tests to ensure physics works properly.
Analysis
- The basic test layout could be to create a scene, make it current and simulate a certain number of frames with a fixed timestep, similar to the sandbox single-frame step.
- Tests could include:
- A ball falling down onto a platform.
- Non-static bodies not depending on parent transform, unless
AllowParent
was set to true. - Probably lots of others, including properties, joints, etc., but keep it short and simple for now.
Issue Analytics
- State:
- Created 6 years ago
- Comments:12 (12 by maintainers)
Top Results From Across the Web
Unity testing framework with physics interaction
The goal of this article is to give some practical example of testing high level interaction that involves 3D physics (rigid bodies) simulation....
Read more >Video Game Physics Tutorial - Part I: Rigid Body Dynamics
In this tutorial series on physics in games, we'll explore rigid body physics simulation, starting with simple rigid body motion in this article, ......
Read more >Rigidbody physics - Manual
Introduction to Rigidbody physics, Overview of the concepts and fundamental behaviours of the Rigidbody class and component. ; Configure Rigidbody colliders, How ...
Read more >Scripting API: Rigidbody
Control of an object's position through physics simulation. ... SweepTest, Tests if a rigidbody would collide with anything, if it was moved through...
Read more >Unit testing collision
Hello, As the title implies, I'd like to unit test collision. ... While writing this I found out the "Rigidbody.SweepTest" API.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ah that also explains why I had to use Resharper to actually run the tests. In pathfindax I use the NUnit3TestAdapter nuget package so that you don’t need the extension.
Tested it with the Nunit2 extension and now it works without problems. Still maybe consider adding that nuget package to the test projects? That way ppl won’t have to install the extension.
Immediate ToDo