Remove redundant qualifier

This commit is contained in:
Timothy Schenk 2022-12-31 17:46:08 +01:00
parent 0da4341b99
commit 8efa1454e4

View file

@ -9,11 +9,11 @@ public class PacketTests
public void TestPacketInheritingIPacket()
{
var allTypes = AppDomain.CurrentDomain.GetAssemblies().SelectMany(x => x.GetTypes())
.Where(x => x.IsAssignableTo(typeof(Server.Packets.IPacket)) && x.IsClass);
.Where(x => x.IsAssignableTo(typeof(Packets.IPacket)) && x.IsClass);
if (!allTypes.Any())
true.Should().BeTrue("There have been no types found which can be checked");
else
allTypes.All(t => t.GetCustomAttributes<Server.Packets.PacketIdAttribute>().Any())
allTypes.All(t => t.GetCustomAttributes<Packets.PacketIdAttribute>().Any())
.Should().BeTrue("All types inheriting from IPacket should have the PacketIdAttribute attribute.");
}
}