diff --git a/app/views/registrar/invoices/pdf.haml b/app/views/registrar/invoices/pdf.haml index 8312796753..19778ec434 100644 --- a/app/views/registrar/invoices/pdf.haml +++ b/app/views/registrar/invoices/pdf.haml @@ -153,7 +153,7 @@ - if @invoice.cancelled? %dt= Invoice.human_attribute_name :cancelled_at - %dd= l @invoice.cancelled_at, + %dd= l @invoice.cancelled_at %dt= t(:due_date) - if @invoice.cancelled? diff --git a/test/integration/admin_area/invoices_test.rb b/test/integration/admin_area/invoices_test.rb new file mode 100644 index 0000000000..bd315d960f --- /dev/null +++ b/test/integration/admin_area/invoices_test.rb @@ -0,0 +1,13 @@ +require 'test_helper' + +class AdminAreaInvoicesIntegrationTest < ApplicationIntegrationTest + setup do + @invoice = invoices(:one) + sign_in users(:admin) + end + + def test_download_invoice_pdf + get admin_invoice_download_pdf_path(@invoice) + assert_response :ok + end +end \ No newline at end of file diff --git a/test/integration/registrar_area/invoices_test.rb b/test/integration/registrar_area/invoices_test.rb new file mode 100644 index 0000000000..5e5a91b46a --- /dev/null +++ b/test/integration/registrar_area/invoices_test.rb @@ -0,0 +1,13 @@ +require 'test_helper' + +class RegistrarAreaInvoicesIntegrationTest < ApplicationIntegrationTest + setup do + @invoice = invoices(:one) + sign_in users(:api_bestnames) + end + + def test_download_invoice_pdf + get download_pdf_registrar_invoice_path(@invoice) + assert_response :ok + end +end \ No newline at end of file