public void BatchProcess_AddItemWithoutRequest() { var item = new SDataBatchRequestItem(); var added = BatchProcess.Instance.AddToBatch(item); Assert.That(added, Is.False); }
public void BatchProcess_AddItemWithUnsuitableRequest() { var service = new SDataService("http://localhost:59213/sdata/aw/dynamic/-/"); using (var request = new SDataBatchRequest(service) { ResourceKind = "employees" }) { var item = new SDataBatchRequestItem { Url = "http://localhost:59213/sdata/aw/dynamic/-/contacts" }; var added = BatchProcess.Instance.AddToBatch(item); Assert.That(added, Is.False); Assert.That(request.Items, Is.Empty); } }