Ejemplo n.º 1
0
        public override IEnumerable <IFeed> GetFeeds()
        {
            var create = new CreatePlugin(PluginManagerDialog);

            yield return(create);

            var upload = new MyGetUpload(PluginManagerDialog);

            yield return(upload);
        }
Ejemplo n.º 2
0
        public void Create()
        {
            Executing.This(() => CreatePlugin.Test(Verify.Args(new { IsValid = false })))
            .Should().Throw <ArgumentException>()
            .And.Exception.Satisfy(ex => ex.Message.StartsWith("False") && ParamNameIsValid(ex));

            var anon = new { IsValid = true };

            CreatePlugin.Test(Verify.Args(anon));

            anon = null;
            CreatePlugin.Test(Verify.Args(anon));

            Executing.This(() => CreatePlugin.Test(Verify.Args("123"))).Should().Throw <VerifyArgsException>();
        }
Ejemplo n.º 3
0
 public void RegisterPlugin(string url, CreatePlugin ctor)
 {
     plugins.Add(url, ctor);
 }