public void Init()
        {
            System.Diagnostics.Debug.WriteLine("SetUp");

            context = GenerateNewContext();

            context.Industries.AddRange(industries);
            context.SaveChanges();

            IUnitOfWork     uow     = new UnitOfWork(context);
            IndustryService service = new IndustryService(uow);

            controller = new IndustryController(service);
        }
Example #2
0
    private void Awake()
    {
        if (instance == null)
        {
            instance = this;
        }
        else if (instance != this)
        {
            Destroy(gameObject);
        }

        //initialize industry array
        placedFactories = new List <int>();
        allFactories    = new List <List <int> >(36); //DOESNT WORK
        for (int i = 0; i < 36; i++)
        {
            allFactories.Add(new List <int>());
            //allFactories[i] = new List<int>(); //size initially 0 DOESNT WORK
        }
    }
Example #3
0
        public static IndustryController Fixture()
        {
            IndustryController controller = new IndustryController(new IndustryRepository(), "", new LoginView());

            return(controller);
        }
 public static IndustryController Fixture()
 {
     IndustryController controller = new IndustryController(new IndustryRepository(), "", new LoginView());
     return controller;
 }
 public void TearDown()
 {
     controller = null;
     context.Database.Delete();
     context = null;
 }