I have a .NET 4.5 proj that is using async/await
functionality.
When i try to inspect/quickwatch a variable reference after an await statement, i get the following:
The name 'id' does not exist in the current context
Know how to fix this so i can debug it?
Edit-- here's the code
[Fact]
public async Task works_as_expected()
{
var repo = Config.Ioc.GetInstance<IAsyncRepository<Customer>>();
var work = Config.Ioc.GetInstance<IUnitOfWork>();
Customer c= new Customer()
{
FirstName = "__Micah",
LastName = "__Smith_test",
DateCreated = DateTime.Now,
DateModified = DateTime.Now,
Email = "m@m.com",
Phone = "7245551212"
};
var id=await repo.Insert(c);
// i can't inspect the value of id
Assert.True(id > 0);
}