Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 28, 2026

Invoice rounding tests were failing because posting creates G/L Account lines with blank VAT Product Posting Group, but no VAT Posting Setup existed for that combination (e.g., 'DOMESTIC' + '').

Changes

  • Extended ConfigureVATPostingSetup() to create VAT Posting Setups with blank VAT Product Posting Group for all VAT Business Posting Groups
  • Configured these setups with 0% VAT and Tax Category 'O' for invoice rounding scenarios

Tests Fixed

  • ExportXml_SalesInvoiceLCY_InvRounding_Positive
  • ExportXml_SalesInvoiceLCY_InvRounding_Negative
  • ExportXml_SalesInvoiceLCY_InvRounding_NegativeTwoDiffVAT
  • ExportXml_SalesCrMemoLCY_InvRounding_Positive
  • ExportXml_ServiceInvoiceLCY_InvRounding_Positive

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Magnus Hartvig Grønbech and others added 15 commits January 23, 2026 17:30
#6311)

The PEPPOL BIS Billing test's `Initialize()` method called
`CompanyInfo.Get()` without ensuring the record exists, causing test
failures in clean database scenarios.

## Changes

Added existence check before accessing Company Information record:

```al
// Before
CompanyInfo.Get();

// After
if not CompanyInfo.Get() then begin
    CompanyInfo.Init();
    CompanyInfo.Insert();
end;
```

This follows standard AL pattern for setup records and ensures tests run
regardless of initial database state.

<!-- START COPILOT CODING AGENT SUFFIX -->



<!-- START COPILOT ORIGINAL PROMPT -->



<details>

<summary>Original prompt</summary>

> Pull Request: #6267
> 
> There is an issue currently in they no company information record
exist.
> 
> In the initialise method in the test, ensure it exists, and set some
default values.


</details>



<!-- START COPILOT CODING AGENT TIPS -->
---

💬 We'd love your input! Share your thoughts on Copilot coding agent in
our [2 minute survey](https://gh.io/copilot-coding-agent-survey).

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Groenbech96 <17690329+Groenbech96@users.noreply.github.com>
Removed multiple test folder entries and added a specific test folder for PEPPOL.
Copilot AI and others added 2 commits January 28, 2026 18:30
Co-authored-by: Groenbech96 <17690329+Groenbech96@users.noreply.github.com>
Co-authored-by: Groenbech96 <17690329+Groenbech96@users.noreply.github.com>
Copilot AI changed the title [WIP] Add PEPPOL tests Fix VAT Posting Setup for invoice rounding in PEPPOL tests Jan 28, 2026
Copilot AI requested a review from Groenbech96 January 28, 2026 18:34
Base automatically changed from private/magnushar/morepeppol to main January 30, 2026 08:40
@github-actions
Copy link

Could not find a linked ADO work item. Please link one by using the pattern 'AB#' followed by the relevant work item number. You may use the 'Fixes' keyword to automatically resolve the work item when the pull request is merged. E.g. 'Fixes AB#1234'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants