Flurl.Http v3.0.0-pre3b Release Notes

Release Date: 2019-11-09 // over 4 years ago
  • ๐Ÿš€ [Features to be pre-released incrementally. Will update here.]

    ๐Ÿ†• New Features

    • FlurlResponse introduced, primarily to enable inspecting response and deserializing body in separate steps (#354)
    • โœ… Tests can be set up to return different fake responses depending on the URL or any other request conditions (#481)
    • โœ… HttpTest.ForCallsTo(...).AllowRealHttp() for allowing real calls to be made in a test for specific URLs or any other request conditions (#225)
    • All extension methods on Flurl.Url and string are now also available on System.Uri (#489)

    ๐Ÿ’ฅ Breaking Changes from 2.x

    • Fluent methods that previously returned HttpResponseMessage (such GetAsync, PostAsync, etc) now return FlurlResponse. If you're using GetJsonAsync or chaining ReceiveXXX methods, this shouldn't break anything (#354)
    • ๐Ÿšš HttpCall is now FlurlCall, and several properties of FlurlCall and FlurlHttpException were moved or renamed (#488)
    • When asserting a specific URL was called, it must be a full string match rather than "contains" or "starts with". Add a * wildcard to the beginning or end if you need partial match behavior (#323)
    • โœ… When faking responses in tests, the last response in the queue becomes "sticky" rather than falling back to empty 200 responses (#482)
    • ๐Ÿ— HttpTest.ResponseQueue public property has been removed. Underlying queue implementation changed significantly to support new features, and hopefully accessing it directly isn't needed. Use RespondWith methods to build the queues.

    ๐Ÿ› Bug Fixes

    • โœ… In tests, dequeuing fake responses is fully thread-safe (#366)