
Explore unit testing in Unity with practical workflows, using the test runner to secure production code, enable unit tests alongside production code, and boost maintenance confidence.
unit testing adds value to Unity game development by supporting test-driven development and automated testing, enabling maintainable, modular architectures, early bug detection, and faster feature growth.
Boost confidence in your code with unit testing in Unity, making refactors bolder and safer. Automate tests to run before and after changes, supporting test-driven development and smaller, testable designs.
Learn to validate a simple Unity math class with unit tests using arrange, act, and assert, ensuring correct add and subtract operations.
The course philosophy provides training to build software with confidence, performance, and scalability, and promotes active learning with videos, quizzes, assignments, and hands-on code practice.
Explore Unity as a real-time engine and middleware powering 2D, 3D, VR, and AR experiences. See its built-in features and optional services, UI, input, rendering, animation, and C# scripting.
Explore the Unity structure by examining scenes, game objects, components, and prefabs, and learn how Unity Editor and C# scripts drive development, testing, and deployment across the software life cycle.
Explore the Unity editor layout featuring hierarchy, scene, project, and inspector windows. Create a game object, attach a script, and tweak serialized fields to see runtime behavior.
Explore core software design principles, including solid principles and don't repeat yourself, and keep it simple, to boost planning, communication, and maintainability in Unity projects.
Explore how unit testing and automated tests boost robustness in Unity projects, using MVC for decoupled code, test driven development, and the Unity test runner across edit and play modes.
Set up unity test framework via the package manager, and use test runner window to create tests in edit and play modes with arrange, act, and assert; enable code coverage.
Create unit tests in Unity with a test class and methods using arrange, act, and assert, exploring edit mode and play mode tests via Unity test framework and test runner.
Practice test driven development, or TDD, by writing a failing test, adding just enough production code to compile, and refactoring until the test passes, then repeat.
Master unit testing in Unity through hands-on workshops that cover a math system, a data loader, and physics-based character movement, emphasizing arrange-act-assert and async testing with a sample project.
Explore the my math system through a Unity unit testing workshop. Learn edit and play mode testing, test runners, and parameterized values.
Examine a basic Unity data loader that loads text from a URL and is tested in isolation. Learn to handle asynchronous web requests and minimize dependencies for dependable unit tests.
Master unit testing in Unity with the data loader advanced, using dependency injection to swap in mock network services and run fast, isolated tests.
Explore unit testing in Unity by inspecting a basic character script driven by the input system and arrow keys, with MonoBehaviour dependencies and play mode versus edit mode tests.
Explore advanced unit testing in Unity by separating monobehaviour from non monobehaviour in a character class. See how this code separation enhances testability and manages dependencies without a substitute library.
Test character physics in Unity with fuzzy, time-dependent movement using separated monobehaviour and non-monobehaviour code. Run play mode tests to validate move position and add force driven motion.
Learn how to unit test Unity prefabs using play mode tests, including loading assets, instantiating prefabs, and validating serialized fields and components like rigidbody.
Master Unity scene loading with play mode tests to smoke test scene integrity, verify hero presence, and ensure no exceptions, while automating build settings to support reliable scene validation.
Explore playmode and edit mode tests, manage asynchronous functionality, and reduce dependencies through dependency injection and separating concerns, including converting monobehaviour code to lighter non monobehaviour classes.
Explore the art and science of unit testing in Unity, blending best practices with creative, user-focused approaches to game development and software systems.
Discover pure functions and their determinism, no side effects, and independence from external systems; learn to refactor impure code with test doubles and prioritize a single assertion per test.
Explore test doubles in unit testing, comparing solitary and sociable tests, and learn how dummy, stub, spy, mock, fake, and bake support reliable tests with NSubstitute.
Explore a Unity C# demo of pure and non-pure functions, and learn to use test doubles—dummy, stub, spy, mock, and fake—within edit-mode tests using the test runner.
Explore how artificial intelligence enhances Unity game development by aiding production code and unit testing, using tools like ChatGPT and Copilot to generate tests, assets, and faster debugging.
Explore using artificial intelligence for production code in Unity, with code generation and design optimization via ChatGPT and GitHub Copilot, including a practical product manager example and unit testing ideas.
Use artificial intelligence to automate unit testing in Unity, generating and refining tests for a product manager class, with arrange, act, and assert patterns and iterative naming tweaks.
Implement CI/CD with Unity by integrating continuous integration, continuous delivery, automated unit testing, and using Unity Cloud Build and version control to automate builds, tests, and deployment to end users.
Explore how to set up and use Unity Cloud Build for CI/CD in Unity projects, automating unit tests, builds, and deployments with triggers and cloud history.
Welcome to Unit Testing For Unity!
UNITY 6:
Course Content: These lessons apply to current and future versions of Unity 6
Course Downloads: All downloadable source-code has been updated to Unity 6
CAPTIONS:
• English: All videos have English subtitles. (Audio/Video/Text Content is in English)
• French: Toutes les vidéos sont sous-titrées en Français. (Audio/Video/Text Content is in English)
• Portuguese: Todos os vídeos têm legendas em Português. (Audio/Video/Text Content is in English)
• German: Alle Videos haben Deutsche Untertitel. (Audio/Video/Text Content is in English)
• Spanish: Todos los vídeos tienen subtítulos en Español. (Audio/Video/Text Content is in English)
• Turkish: Tüm videolar Türkçe altyazılıdır. (Audio/Video/Text Content is in English)
We all start projects with the best of intentions. But during development we often find our projects do not meet our expectations for organization, scalability, and for our quality of life as developers.
This course gives you the training to create and maintain robust Unity classes and architectures.
FEATURES:
Rockstar content - Everything you DO need. Just the most relevant, powerful info!
Punk-rock editing - Nothing you DON'T need. No "ums", no waiting, no fluff!
BENEFITS OF UNIT TESTING:
Early Bug Detection - Running unit tests after every build helps in identifying any breakage at the earliest possible instance, saving time and resources
Refactoring Confidence - With a comprehensive suite of unit tests, developers can refactor code more aggressively and with assurance, knowing tests will reveal any introduced errors
Better Design -Writing unit tests forces developers to consider the modularity and structure of their code, often leading to better-designed and more maintainable software
BENEFITS OF TEST-DRIVEN-DEVELOPMENT (TDD):
Improved Code Quality - TDD encourages simple designs and inspires confidence, as code changes are verified by tests frequently
Documentation Benefit - Tests written in TDD can serve as a form of documentation, showing how the system is intended to behave
Reduction in Errors - TDD typically results in a lower bug density in production, as tests are written before the code that must pass them
TAKEAWAY:
After this course you will be confident to design and develop well-designed and tested Unity classes. Learn to write robust C# code that your team will be proud of.
INCLUDED SECTIONS:
Course Introduction - Set the vision and goals for the course. Learn the many benefits of MVC architecture for your projects
Unity Overview - Review the popularity and power of Unity as a game engine. Discuss the structure of the systems within and how MVC architecture is a welcome addition
Unit Testing Fundamentals - We'll add the power of Unit Testing and Test-Driven Development ( TDD ). With this training you will naturally produce cleaner, more readable, and manageable code
Unit Testing Workshops - Take the fundamentals and apply them through a series of isolated demos. Each demo has production code, edit-mode tests, and play-mode tests. Perform assignments based on what you have learned
Unit Testing Lessons - Dive deep into the art and science of Unit Testing. Get the theory, apply the practices, and explore topics including "Pure Functions" & "Test Doubles"
Unit Testing with CI/CD - Master continuous integration, continuous deployment. Learn the benefits and complete the setup for your project
And More!
INCLUDED UNITY C# SAMPLE PROJECTS:
1. Math System - A simple calculator without a rendered view. This is a great place to learn the fundamentals of testing without the complications of Unity MonoBehaviours or rendered graphics
2. Data Loader Basic - Learn how to handle async/await operations and test for robust results
3. Data Loader Advanced - We create more stability and confidence with C# code refactors
4. Character Basic - A game character that moves with user input. Add Unity MonoBehaviours and rendered graphics to the challenges of testing. Learn to master the challenges
5. Character Advanced - A game character that moves with user input. Learn to test asynchronous methods such as multi-frame movement
6. Character Physics - A game character that uses physics. Learn to isolate dependencies and refactor systems efficiently
7. Testing Prefabs - Full demo
8. Testing Scenes - Tips and tricks
Plus More!
INCLUDED ASSETS:
Section Videos - High-quality HD video content covering all course topics
Section Source Code- Full C# scripting and complete Unity projects included for download
Section Challenge Assignments - Expand your knowledge with practical, relevant coding trials
Section Quiz - Ensure you digested all vital info before moving forward
WHY LEARN UNITY?
Unity is a versatile game engine which can be used for creating simulations, prototypes, and games
Over 70% of the top 1000 mobile games are created using Unity Technology
Deploys to PC, Xbox, PlayStation, iOS, & Android, WebGL, AR/VR, and more!
WHY LEARN UNIT TESTING?
1. Accelerate new features - With testing, developers focus on a small batch of code at a time, not moving on to the next bit until they are done with their batch. This gets results
2. Level-up your maintenance - With Test-Driven Development ( TDD ), developers naturally produce cleaner, more readable, and manageable code
3. Fail fast & Communicate clearly - Get feedback quickly and improve your solutions. Leave a legacy of unit testing in your codebase which will serve as the best, living documentation
WHY LEARN WITH SAMUEL ASHER RIVELLO?
Sam is a Unity Certified Developer with over 20 years of experience creating games and teaching software design
Sam empowers game teams with custom editor tooling for improved workflows ( Game Design, Level Design, 3D Modelers, 3D Animators )
Sam is an author and editor, including Adobe, Future Publishing UK, Packt Publishing, and O’Reilly
WHY WAIT?
Avoid the common pitfalls with creating, maintaining, and scaling your Unity classes
You can't afford NOT to use Unit Testing and Test-Driven development on your projects
Let's do this!