Search Unity

  1. Unity 2018.3 is now released.
    Dismiss Notice
  2. The Unity Pro & Visual Studio Professional Bundle gives you the tools you need to develop faster & collaborate more efficiently. Learn more.
    Dismiss Notice
  3. We've updated our Terms of Service. Please read our blog post from Unity CTO and Co-Founder Joachim Ante here
    Dismiss Notice
  4. Want to provide direct feedback to the Unity team? Join the Unity Advisory Panel.
    Dismiss Notice
  5. Improve your Unity skills with a certified instructor in a private, interactive classroom. Watch the overview now.
    Dismiss Notice

Unit tests failing

Discussion in 'Entity Component System and C# Job system' started by tertle, Jan 11, 2019.

  1. tertle

    tertle

    Joined:
    Jan 25, 2011
    Posts:
    910
    This has bothered me for months, why do some of the Unity.Entities.Hybrid.Tests unit tests fail? =(

    upload_2019-1-12_8-11-46.png
     
  2. Joachim_Ante

    Joachim_Ante

    Unity Technologies

    Joined:
    Mar 16, 2005
    Posts:
    4,232
    Which one specifically fails.
     
  3. tertle

    tertle

    Joined:
    Jan 25, 2011
    Posts:
    910
    So three of them are failing

    Both ComponentDataWrapper_SetValue_SynchronizesWithEntityManager tests

    and

    Initialize_ShouldLogNothing under DefaultWorldInitializationTests

    I haven't actually looked at tests, but I'm pretty sure just from the error the issue is I don't use the default world initialization and instead use a custom world setup, therefore some systems don't have empty constructors.

    I think the only solution is probably disabling the DefaultWorld related tests if UNITY_DISABLE_AUTOMATIC_SYSTEM_BOOTSTRAP is set in the project.

    Not a big deal anyway, just a slight annoyance as I seem to need to include the ecs tests if I want to use ECSTestsFixture in my own tests.
     
  4. Fido789

    Fido789

    Joined:
    Feb 26, 2013
    Posts:
    328
    No need to use ECSTestsFixture, you can just make your own similar base test class.