From 208f7a0c0d1603e35141cf0530521bcc0c31714f Mon Sep 17 00:00:00 2001 From: metalgearsloth <31366439+metalgearsloth@users.noreply.github.com> Date: Mon, 2 Aug 2021 15:03:34 +1000 Subject: [PATCH] SetTile during extensions test (#4409) Mainly so it can actually account for accurate grid bounds when doing the test Co-authored-by: metalgearsloth --- .../Tests/Utility/EntitySystemExtensionsTest.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Content.IntegrationTests/Tests/Utility/EntitySystemExtensionsTest.cs b/Content.IntegrationTests/Tests/Utility/EntitySystemExtensionsTest.cs index 08f8a411f5..b33ccc3a57 100644 --- a/Content.IntegrationTests/Tests/Utility/EntitySystemExtensionsTest.cs +++ b/Content.IntegrationTests/Tests/Utility/EntitySystemExtensionsTest.cs @@ -5,6 +5,7 @@ using Content.Shared.Spawning; using NUnit.Framework; using Robust.Shared.GameObjects; using Robust.Shared.Map; +using Robust.Shared.Maths; using Robust.Shared.Physics; using Robust.Shared.Physics.Broadphase; @@ -44,7 +45,9 @@ namespace Content.IntegrationTests.Tests.Utility await server.WaitAssertion(() => { + var mapId = new MapId(1); var grid = sMapManager.GetGrid(new GridId(1)); + grid.SetTile(new Vector2i(0, 0), new Tile(1)); var entityCoordinates = new EntityCoordinates(grid.GridEntityId, 0, 0); // Nothing blocking it, only entity is the grid @@ -52,7 +55,6 @@ namespace Content.IntegrationTests.Tests.Utility Assert.True(sEntityManager.TrySpawnIfUnobstructed(null, entityCoordinates, CollisionGroup.Impassable, out var entity)); Assert.NotNull(entity); - var mapId = new MapId(1); var mapCoordinates = new MapCoordinates(0, 0, mapId); // Nothing blocking it, only entity is the grid