spec/fixtures/vcr_cassettes/translate_texts.yml in deepl-rb-1.0.1 vs spec/fixtures/vcr_cassettes/translate_texts.yml in deepl-rb-2.0.0

- old
+ new

@@ -21,25 +21,24 @@ message: OK headers: Server: - nginx Date: - - Sun, 10 Dec 2017 20:34:26 GMT + - Tue, 08 May 2018 16:31:36 GMT Content-Type: - application/json Content-Length: - - '78' + - '74' Connection: - keep-alive Access-Control-Allow-Origin: - "*" body: encoding: UTF-8 - string: '{"translations":[{"detected_source_language":"EN","text":"Texto de - muestra"}]}' - http_version: - recorded_at: Sun, 10 Dec 2017 20:34:26 GMT + string: '{"translations":[{"detected_source_language":"EN","text":"Texto de muestra"}]}' + http_version: + recorded_at: Tue, 08 May 2018 16:31:34 GMT - request: method: post uri: https://api.deepl.com/v1/translate?auth_key=VALID_TOKEN body: encoding: US-ASCII @@ -59,11 +58,11 @@ message: OK headers: Server: - nginx Date: - - Sun, 10 Dec 2017 20:34:26 GMT + - Tue, 08 May 2018 16:31:37 GMT Content-Type: - application/json Content-Length: - '120' Connection: @@ -71,18 +70,18 @@ Access-Control-Allow-Origin: - "*" body: encoding: UTF-8 string: '{"translations":[{"detected_source_language":"EN","text":"Muestra"},{"detected_source_language":"EN","text":"Palabra"}]}' - http_version: - recorded_at: Sun, 10 Dec 2017 20:34:26 GMT + http_version: + recorded_at: Tue, 08 May 2018 16:31:35 GMT - request: method: post - uri: https://api.deepl.com/v1/translate?auth_key=invalid + uri: https://api.deepl.com/v1/translate?auth_key=VALID_TOKEN body: encoding: US-ASCII - string: text=Sample+text&source_lang=EN&target_lang=ES + string: text=%3Cp%3ESample+text%3C%2Fp%3E&source_lang=EN&target_lang=ES headers: Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: - "*/*" @@ -90,32 +89,37 @@ - Ruby Content-Type: - application/x-www-form-urlencoded response: status: - code: 403 - message: Forbidden + code: 200 + message: OK headers: Server: - nginx Date: - - Sun, 10 Dec 2017 20:34:27 GMT + - Tue, 08 May 2018 16:31:37 GMT + Content-Type: + - application/json Content-Length: - - '0' + - '85' Connection: - keep-alive + Access-Control-Allow-Origin: + - "*" body: encoding: UTF-8 - string: '' - http_version: - recorded_at: Sun, 10 Dec 2017 20:34:27 GMT + string: '{"translations":[{"detected_source_language":"EN","text":"<p>Texto + de muestra</p>"}]}' + http_version: + recorded_at: Tue, 08 May 2018 16:31:36 GMT - request: method: post - uri: https://api.deepl.com/v1/translate?auth_key=VALID_TOKEN + uri: https://api.deepl.com/v1/translate?auth_key=invalid body: encoding: US-ASCII - string: source_lang=EN&target_lang=ES + string: text=Sample+text&source_lang=EN&target_lang=ES headers: Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: - "*/*" @@ -123,32 +127,32 @@ - Ruby Content-Type: - application/x-www-form-urlencoded response: status: - code: 400 - message: Bad Request + code: 403 + message: Forbidden headers: Server: - nginx Date: - - Sun, 10 Dec 2017 20:34:27 GMT + - Tue, 08 May 2018 16:31:38 GMT Content-Length: - - '45' + - '0' Connection: - keep-alive body: encoding: UTF-8 - string: '{"message":"Parameter ''text'' not specified."}' - http_version: - recorded_at: Sun, 10 Dec 2017 20:34:27 GMT + string: '' + http_version: + recorded_at: Tue, 08 May 2018 16:31:37 GMT - request: method: post uri: https://api.deepl.com/v1/translate?auth_key=VALID_TOKEN body: encoding: US-ASCII - string: text=Sample+text&source_lang=EN + string: source_lang=EN&target_lang=ES headers: Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: - "*/*" @@ -162,26 +166,26 @@ message: Bad Request headers: Server: - nginx Date: - - Sun, 10 Dec 2017 20:34:28 GMT + - Tue, 08 May 2018 16:31:38 GMT Content-Length: - - '52' + - '45' Connection: - keep-alive body: encoding: UTF-8 - string: '{"message":"Parameter ''target_lang'' not specified."}' - http_version: - recorded_at: Sun, 10 Dec 2017 20:34:28 GMT + string: '{"message":"Parameter ''text'' not specified."}' + http_version: + recorded_at: Tue, 08 May 2018 16:31:37 GMT - request: method: post uri: https://api.deepl.com/v1/translate?auth_key=VALID_TOKEN body: encoding: US-ASCII - string: text=%3Cp%3ESample+text%3C%2Fp%3E&source_lang=EN&target_lang=ES + string: text=Sample+text&source_lang=EN headers: Accept-Encoding: - gzip;q=1.0,deflate;q=0.6,identity;q=0.3 Accept: - "*/*" @@ -189,27 +193,22 @@ - Ruby Content-Type: - application/x-www-form-urlencoded response: status: - code: 200 - message: OK + code: 400 + message: Bad Request headers: Server: - nginx Date: - - Thu, 04 Jan 2018 18:09:50 GMT - Content-Type: - - application/json + - Tue, 08 May 2018 16:31:39 GMT Content-Length: - - '85' + - '52' Connection: - keep-alive - Access-Control-Allow-Origin: - - "*" body: encoding: UTF-8 - string: '{"translations":[{"detected_source_language":"EN","text":"<p>Texto - de muestra</p>"}]}' - http_version: - recorded_at: Thu, 04 Jan 2018 18:09:49 GMT + string: '{"message":"Parameter ''target_lang'' not specified."}' + http_version: + recorded_at: Tue, 08 May 2018 16:31:37 GMT recorded_with: VCR 4.0.0