From d97e50fced61a916eb91c2e22df6841a89158bd2 Mon Sep 17 00:00:00 2001 From: Marek Lipka Date: Mon, 27 Feb 2023 17:35:44 +0100 Subject: [PATCH] Add post_city to returned data, bump version --- lib/gus_bir1/response/search.rb | 1 + lib/gus_bir1/version.rb | 2 +- test/gus_bir1_test.rb | 6 ++++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/lib/gus_bir1/response/search.rb b/lib/gus_bir1/response/search.rb index 64daf5e..52be517 100644 --- a/lib/gus_bir1/response/search.rb +++ b/lib/gus_bir1/response/search.rb @@ -34,6 +34,7 @@ def parse_dane(hash) search_result.type_desc = type_info(search_result) search_result.silos_desc = silos_info(search_result) search_result.report = report_info(search_result) + search_result.post_city = hash['MiejscowoscPoczty'] search_result end diff --git a/lib/gus_bir1/version.rb b/lib/gus_bir1/version.rb index d71e108..96da84c 100644 --- a/lib/gus_bir1/version.rb +++ b/lib/gus_bir1/version.rb @@ -1,5 +1,5 @@ # frozen_string_literal: true module GusBir1 - VERSION = '1.2.0' + VERSION = '1.2.1' end diff --git a/test/gus_bir1_test.rb b/test/gus_bir1_test.rb index d46a206..d275676 100644 --- a/test/gus_bir1_test.rb +++ b/test/gus_bir1_test.rb @@ -27,7 +27,8 @@ def setup report: 'PublDaneRaportPrawna', street_number: '208', house_number: nil, - street_address: "ul. Test-Krucza 208" + street_address: "ul. Test-Krucza 208", + post_city: 'Warszawa' } @psp_hash = { @@ -46,7 +47,8 @@ def setup report: 'PublDaneRaportPrawna', street_number: '15', house_number: nil, - street_address: "ul. Test-Krucza 15" + street_address: "ul. Test-Krucza 15", + post_city: 'Wrocław' } end