Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • C CDNTaxReceipts
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 32
    • Issues 32
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 6
    • Merge requests 6
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Extensions
  • CDNTaxReceipts
  • Merge requests
  • !159

Explicitly specify report field types to match changes in core

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged DaveD requested to merge DaveD/cdntaxreceipts:report-field-type into master Nov 25, 2021
  • Overview 4
  • Commits 1
  • Pipelines 0
  • Changes 2

Recent change in core makes the data type string if you don't explicitly specify. So in tests 1 wasn't matching '1', e.g.

CRM_Cdntaxreceipts_ReceiptsIssuedReportTest::testReport
Failed asserting that two arrays are equal.
--- Expected
+++ Actual
@@ @@
 Array (
     0 => Array (
         'civicrm_contact_sort_name' => 'Miller, Joe'
-        'civicrm_contact_id' => 3
+        'civicrm_contact_id' => '3'
         'civicrm_cdntaxreceipts_log_issued_on' => '2021-11-25'
         'civicrm_cdntaxreceipts_log_receipt_amount' => '10.00'
         'civicrm_cdntaxreceipts_log_receipt_no' => 'C-00000001'
         'civicrm_cdntaxreceipts_log_issue_type' => 'Single'
         'civicrm_cdntaxreceipts_log_issue_method' => 'Print'
-        'civicrm_cdntaxreceipts_log_uid' => 1
+        'civicrm_cdntaxreceipts_log_uid' => '1'
         'civicrm_cdntaxreceipts_log_receipt_status' => 'Issued'
         'civicrm_cdntaxreceipts_log_email_opened' => null
-        'civicrm_cdntaxreceipts_log_contributions_contribution_id' => 1
+        'civicrm_cdntaxreceipts_log_contributions_contribution_id' => '1'
         'civicrm_contact_sort_name_link' => '/index.php?q=civicrm/contact/...;cid=3'
         'civicrm_contact_sort_name_hover' => 'View Contact Summary for this Contact'
+        'class' => null
     )
 )
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: report-field-type