public void TestChargeWithSufficientSupply() { Model model = new Model("Test Model", Guid.NewGuid()); MaterialCatalog mcat = LoadSampleCatalog(); MaterialService source = new MaterialService(model, "Sorc", Guid.NewGuid(), 3, 100, mcat, 37.0); source.AddCompartment(model, mcat["Ammonia"].Guid, 1500, 17, 2000, Guid.NewGuid()); MaterialService sink = new MaterialService(model, "Sink", Guid.NewGuid(), 3, 100, mcat, 37.0); sink.AutocreateMaterialCompartments = true; TestClient tc = new TestClient(model, source, sink, mcat["Ammonia"], 1000, mcat["Ammonia"], 750); model.Executive.RequestEvent( new ExecEventReceiver(tc.Run), new DateTime(2009, 2, 16, 12, 59, 28), 0.0, new Hashtable(), ExecEventType.Detachable); model.Start(); }