public async Task SetErrorAsyncTest() { var job = new Job { AppID = AppID, Created = DateTime.Now, Status = null, ProcessID = processID }; job = await jobDAL.SetJobAsync(job); Assert.True(!string.IsNullOrWhiteSpace(job.JobID)); var error = "Test Error"; var count = await jobDAL.SetErrorAsync(job.ProcessID, job.JobID, error); var outJob = await jobDAL.GetJobAsync(job.JobID); await jobDAL.DeleteAsync(new List <string> { job.JobID }); Assert.NotNull(outJob); Assert.True(count == 1); Assert.Equal(JobStatus.Error, outJob.Status); Assert.Equal(error, outJob.Error); }