Skip to content

Commit

Permalink
Merge pull request #7 from kostas-s/add_qr_code_to_response_xsd
Browse files Browse the repository at this point in the history
Add qr code to response xsd
  • Loading branch information
mikezaby authored Dec 6, 2023
2 parents f8da691 + 35b5f2a commit 512ef40
Show file tree
Hide file tree
Showing 3 changed files with 108 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/my_data/xsd/docs/response-v1.0.2.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,11 @@
<xs:documentation>Συμβολοσειρά Αυθεντικοποίησης Παρόχου</xs:documentation>
</xs:annotation>
</xs:element>
<xs:element name="qrUrl" type="xs:string" minOccurs="0">
<xs:annotation>
<xs:documentation>QR Code Url</xs:documentation>
</xs:annotation>
</xs:element>
</xs:sequence>
<xs:element name="errors">
<xs:annotation>
Expand Down
95 changes: 95 additions & 0 deletions spec/cassettes/send_invoices_success_modified_v1_0_7.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 8 additions & 0 deletions spec/lib/my_data/client_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,14 @@
expect(response_parser.errors).to be_empty
end
end

context "when request is successful (myDATA API 1.0.7)", vcr: { cassette_name: "send_invoices_success_modified_v1_0_7", match_requests_on: [:body] } do

Check warning on line 162 in spec/lib/my_data/client_spec.rb

View workflow job for this annotation

GitHub Actions / RuboCop

spec/lib/my_data/client_spec.rb#L162

Line is too long. [155/120] (Layout/LineLength)
let(:doc) { build(:invoices_doc).to_xml }

it "has proper qr_url" do
expect(response_parser.response.response.first.qr_url).to eq("https://mydataapidev.aade.gr/TimologioQR/QRInfo?q=encoded_string_replaced_on_cassette")
end
end
end

describe "#cancel_invoice" do
Expand Down

0 comments on commit 512ef40

Please sign in to comment.