public void CorrectRequestForCreate() {
            var factory = Substitute.For<IConnection>();
            var client = new VpcClient(factory);

            var body = new Models.Requests.Vpc();
            client.Create(body);

            factory.Received().ExecuteRequest<Vpc>("vpcs", null, body, "vpc", Method.POST);
        }
示例#2
0
 /// <summary>
 /// To create a VPC.
 /// </summary>
 public Task <Vpc> Create(Models.Requests.Vpc vpc)
 {
     return(_connection.ExecuteRequest <Vpc>("vpcs", null, vpc, "vpc", Method.POST));
 }