Ejemplo n.º 1
0
        private static void ReflectionFactoryTest()
        {
            Logger.AddTestStep("Testing ReflectionFactory");

            Furniture furniture = null;

            furniture = ReflectionFactory.GetFurniture <CoffeeTable>();
            Console.WriteLine(string.Format("We ordered coffee table and we've got: {0}", furniture.Name));

            var assembly = Assembly.LoadFile(Environment.CurrentDirectory + @"\Library.dll");

            furniture = ReflectionFactory.GetFurniture(assembly.ExportedTypes.First().FullName);
            Console.WriteLine(string.Format("We ordered large desk and we've got: {0}", furniture.Name));
        }