public void CorrectRequestForCreateMany() { var factory = Substitute.For <IConnection>(); var client = new DropletsClient(factory); var body = new Models.Requests.Droplets(); client.Create(body); factory.Received().ExecuteRequest <List <Droplet> >("droplets", null, body, "droplets", Method.POST); }
/// <summary> /// To create multiple Droplets. /// A Droplet will be created for each name you send using the associated information. /// Up to ten Droplets may be created at a time. /// </summary> public Task <IReadOnlyList <Droplet> > Create(Models.Requests.Droplets droplets) { return(_connection.ExecuteRequest <List <Droplet> >("droplets", null, droplets, "droplets", Method.POST) .ToReadOnlyListAsync()); }