public void Default_MvcBlade_Returns_Filled_Registration_List() {
            var blade = new RoutingBlade();

            var list = new AutoRegistrationList();
            blade.AddRegistrations(list);

            Assert.IsNotEmpty(list.ToList());
            Assert.AreEqual(list.Count(), 1);
        }
        public void Default_MvcBlade_Returns_Filled_Registration_List_With_MVC_Registrations() {
            var blade = new RoutingBlade();

            var list = new AutoRegistrationList();
            blade.AddRegistrations(list);

            foreach (ServiceRegistration registration in list) {
                Assert.IsTrue(registration.IsValid());
            }
        }
Exemplo n.º 3
0
        public void Default_MvcBlade_Returns_Filled_Registration_List()
        {
            var blade = new RoutingBlade();

            var list = new AutoRegistrationList();

            blade.AddRegistrations(list);

            Assert.IsNotEmpty(list.ToList());
            Assert.AreEqual(list.Count(), 1);
        }
        public void Null_Service_Locator_Should_Throw_InvalidOperationException() {
            var context = Get<IRotorContext>();

            using (Record()) {
                Expect.Call(context.ServiceLocator).Return(null);
            }

            using (Playback()) {
                var blade = new RoutingBlade();
                blade.Spin(context);
            }
        }
Exemplo n.º 5
0
        public void Null_Service_Locator_Should_Throw_InvalidOperationException()
        {
            var context = Get <IRotorContext>();

            using (Record()) {
                Expect.Call(context.ServiceLocator).Return(null);
            }

            using (Playback()) {
                var blade = new RoutingBlade();
                blade.Spin(context);
            }
        }
Exemplo n.º 6
0
        public void Default_MvcBlade_Returns_Filled_Registration_List_With_MVC_Registrations()
        {
            var blade = new RoutingBlade();

            var list = new AutoRegistrationList();

            blade.AddRegistrations(list);

            foreach (ServiceRegistration registration in list)
            {
                Assert.IsTrue(registration.IsValid());
            }
        }
Exemplo n.º 7
0
        public void Null_Rotor_Context_Should_Throw_ArgumentNullException()
        {
            var blade = new RoutingBlade();

            blade.Spin(null);
        }
Exemplo n.º 8
0
 public void Routing_Blade_Is_Not_Core_Blade()
 {
     bool result = new RoutingBlade().IsCoreBlade();
     Assert.IsFalse(result);
 }
        public void Routing_Blade_Is_Not_Core_Blade()
        {
            bool result = new RoutingBlade().IsCoreBlade();

            Assert.IsFalse(result);
        }
Exemplo n.º 10
0
 public void Null_Rotor_Context_Should_Throw_ArgumentNullException()
 {
     var blade = new RoutingBlade();
     blade.Spin(null);
 }