public void testType() { var shell = new AppDomainShell(); shell.Init(false); shell.Open(typeof(ThreadAttack).Assembly.Location); RobotType type = shell.GetRobotType(typeof(ThreadAttack).FullName); Assert.AreEqual(RobotType.ADVANCED, type); shell.Open(typeof(MyFirstRobot).Assembly.Location); type = shell.GetRobotType(typeof(MyFirstRobot).FullName); Assert.AreEqual(RobotType.STANDARD, type); shell.Dispose(); }
public void testType() { var shell = new AppDomainShell(); shell.Init(false); shell.Open(typeof(ThreadAttack).Assembly.Location); RobotType robotType = shell.GetRobotType(typeof(ThreadAttack).FullName); Assert.IsTrue(robotType.isAdvancedRobot()); shell.Open(typeof(MyFirstRobot).Assembly.Location); robotType = shell.GetRobotType(typeof(MyFirstRobot).FullName); Assert.IsTrue(robotType.isStandardRobot()); shell.Dispose(); }