File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed
Networking/NetworkingTests/Mapper Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -8,11 +8,18 @@ class WCPayChargeMapperTests: XCTestCase {
88
99 /// Verifies that the WCPayCharge is parsed.
1010 ///
11- func test_WCPayCharge_map_parses_all_coupons_in_response ( ) throws {
11+ func test_WCPayCharge_map_parses_data_in_response ( ) throws {
1212 let wcpayCharge = try mapRetrieveWCPayChargeResponse ( )
1313 XCTAssertNotNil ( wcpayCharge)
1414 }
1515
16+ /// Verifies that the WCPayCharge is parsed.
17+ ///
18+ func test_WCPayCharge_map_parses_data_in_response_without_data_envelope( ) throws {
19+ let wcpayCharge = try mapRetrieveWCPayChargeResponse ( responseName: . cardPresentWithoutDataEnvelope)
20+ XCTAssertNotNil ( wcpayCharge)
21+ }
22+
1623 /// Verifies that the `siteID` is added in the mapper, because it's not provided by the API endpoint
1724 ///
1825 func test_WCPayCharge_map_includes_siteID_in_parsed_results( ) throws {
@@ -173,6 +180,7 @@ private extension WCPayChargeMapperTests {
173180
174181 enum ChargeResponse : String {
175182 case cardPresent = " wcpay-charge-card-present "
183+ case cardPresentWithoutDataEnvelope = " wcpay-charge-card-present-without-data "
176184 case cardPresentMinimal = " wcpay-charge-card-present-minimal "
177185 case card = " wcpay-charge-card "
178186 case interacPresent = " wcpay-charge-interac-present "
You can’t perform that action at this time.
0 commit comments