Sameera Perera
Sep 4, 2018 · 1 min read

Nicolas,
Could you try out my `Outcome<T>` library which has support for Promise-like chaining for async methods, and share your thoughts?
https://github.com/sameera/Codoxide.Outcome

For example you can do something like this (even with nested async calls) and it will neatly flatten everything out:

await this.DoAsyncParameterizedOutcome(100d)
.Then(number => {
return this.DoAsyncParameterizedOutcome(number);
}).Then(result => {
result.Should().BeOfType(typeof(double));
return this.DoAsyncOutcome();
}).Then(result => {
result.Should().Be(_theResult);
});

    Sameera Perera

    Written by

    Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
    Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
    Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade