Esempio n. 1
0
 public void TwoArgumentConstructor(int iterations)
 {
     for (int i = 0; i < iterations; i++)
     {
         ClassWithTwoConstructorArgs item = FastActivator <ClassWithTwoConstructorArgs> .Create(47, "The Name");
     }
 }
Esempio n. 2
0
		public void TwoArgumentConstructor(int iterations)
		{
			for (int i = 0; i < iterations; i++)
			{
				var item = new ClassWithTwoConstructorArgs(47, "The Name");
			}
		}
Esempio n. 3
0
 public void TwoArgumentConstructor(int iterations)
 {
     for (int i = 0; i < iterations; i++)
     {
         var item = new ClassWithTwoConstructorArgs(47, "The Name");
     }
 }
Esempio n. 4
0
        public void Using_new_with_two_arguments()
        {
            Trace.WriteLine("Using new(47,TheName)");

            for (int i = 0; i < Iterations; i++)
            {
                var item = new ClassWithTwoConstructorArgs(47, "The Name");
            }
        }
Esempio n. 5
0
        public void Using_object_generator_with_two_arguments()
        {
            Trace.WriteLine("Using FastActivator(47,TheName)");

            for (int i = 0; i < Iterations; i++)
            {
                ClassWithTwoConstructorArgs item = FastActivator <ClassWithTwoConstructorArgs> .Create(47, "The Name");
            }
        }
Esempio n. 6
0
        public void The_object_should_be_created()
        {
            const int    expected     = 47;
            const string expectedName = "The Name";

            _instance = FastActivator <ClassWithTwoConstructorArgs> .Create(expected, expectedName);

            _instance.ShouldNotBeNull();
            _instance.ShouldBeAnInstanceOf <ClassWithTwoConstructorArgs>();
            _instance.Value.ShouldEqual(expected);
            _instance.Name.ShouldEqual(expectedName);
        }
Esempio n. 7
0
        public void Using_new_with_two_arguments()
        {
            Trace.WriteLine("Using new(47,TheName)");

            for (int i = 0; i < Iterations; i++)
            {
                var item = new ClassWithTwoConstructorArgs(47, "The Name");
            }
        }
Esempio n. 8
0
		public void The_object_should_be_created()
		{
			const int expected = 47;
			const string expectedName = "The Name";

			_instance = FastActivator<ClassWithTwoConstructorArgs>.Create(expected, expectedName);

			_instance.ShouldNotBeNull();
			_instance.ShouldBeAnInstanceOf<ClassWithTwoConstructorArgs>();
			_instance.Value.ShouldEqual(expected);
			_instance.Name.ShouldEqual(expectedName);
		}