WorldTest.cs 445 B

123456789101112131415161718192021222324
  1. using System.Threading;
  2. using Helper;
  3. using Microsoft.VisualStudio.TestTools.UnitTesting;
  4. namespace WorldTest
  5. {
  6. [TestClass]
  7. public class WorldTest
  8. {
  9. [TestMethod]
  10. public void TestReload()
  11. {
  12. var world = World.World.Instance;
  13. world.Dispatcher(1, "tanghai".ToByteArray());
  14. int count = 10;
  15. while (--count != 0)
  16. {
  17. world.Dispatcher(1, "tanghai".ToByteArray());
  18. Thread.Sleep(10000);
  19. world.Reload();
  20. }
  21. }
  22. }
  23. }