Ejemplo n.º 1
0
        public void CanConstruct()
        {
            var testPlugin = new TestPlugin();
            var ap         = new AvailablePlugin(testPlugin, this.AssemblyPath);

            Assert.That(ap.Instance, Is.InstanceOf(testPlugin.GetType()));
            Assert.True(ap.AssemblyPath.Equals(this.AssemblyPath));

            var hash = ap.GetHashCode();

            Assert.True(hash != 0);
            Assert.True(ap.ToString().Equals(testPlugin.Name));

            var apClone = new AvailablePlugin(ap.Instance, ap.AssemblyPath);

            Assert.True(ap.Equals(apClone));
        }