Skip to content

[Bug Fix] #531: Seed BEANS purchase inspection generation rule - #12267

Open
business-central-bug-fix-bot[bot] wants to merge 9 commits into
mainfrom
bugs/650223
Open

business-central-bug-fix-bot[bot] wants to merge 9 commits into
mainfrom
bugs/650223

Conversation

@business-central-bug-fix-bot

@business-central-bug-fix-bot business-central-bug-fix-bot Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

What & why

Seed the missing BEANS purchase inspection generation rule in the Quality Management Contoso Coffee demo dataset. BEANS-category purchases, including tracked WRB-1002, now select BEANS ahead of the generic RECEIVE template. Other item categories continue to use RECEIVE.

Root Cause

Create QM Generation Rule created only RECEIVE at sort order 40, although the BEANS template and coffee items already existed. Rule resolution correctly supports item filters and ascending priority; the missing demo configuration was the defect.

Changes Made

  • CreateQMGenerationRule.Codeunit.al: add Purchase/Purchase Line rule 3 at sort order 30, enabled for manual and automatic creation, with an item-category BEANS filter.
  • ContosoQualityManagement.Codeunit.al: add an Item Filter overload while preserving the original helper signature and overwrite protection.
  • CreateQMInspTemplateHdr.Codeunit.al: expose the existing localized BEANS description.
  • QltyTestsGenerationRule.Codeunit.al: add seven regression tests to existing codeunit 139955, using the real demo seeders.
  • Quality Management test app.json: reference the demo dataset so the tests exercise its actual configuration.

The issue fix is commit b0549c777e452d82218188e370c61567ef13b0a3. The supplied branch also contains earlier infrastructure commits; see Risk & compatibility.

Linked work

Fixes microsoft/BCAppsBugFix#531

AB#650223

How I validated this

  • I read the full diff and it contains only changes I intended.
  • I built the affected app(s) locally with no new analyzer warnings.
  • I ran the change in Business Central and confirmed it behaves as expected.
  • I added or updated tests for the new behavior, or explained below why none are needed.

What I tested and the outcome (required — be specific: scenarios, commands, screenshots for UI changes)

The five-file issue-fix diff was inspected and independently accepted. The full PR also includes inherited infrastructure changes that this run did not author, so the first checklist item is intentionally unchecked. All four projects built successfully; saved build responses report no warnings, but the error-filtered diagnostic evidence is not a complete analyzer-warning comparison, so the second combined checklist assertion is intentionally unchecked.

Implementation Process

  • Tests required: yes.
  • Baseline iteration 1: 6 expected failures, 4 passed, 0 skipped.
  • Fix iteration 1 of 5: 10 passed, 0 failed, 0 skipped.
  • Compilation and ordered deployment: Quality Management, Quality Management Contoso Coffee Demo Dataset, Quality Management Test Library, and Quality Management-Tests all succeeded.
  • BeforePublish and BeforeTests readiness: schema version 2, with compiler-symbol, runtime-dependency, and live-endpoint proofs all true.
  • Exact final test artifact SHA256: 334E15A2CC6D17B7B43462583BFFF53AB58CD28EAE3FE557F7D37B12F4334786; installed PackageId: 29ea1b6b-8f87-4a15-b8a0-38f71bec481c.

Validation Evidence

The repository's bug-fix build/publish/test commands were used against the provisioned container; no environment was provisioned by this run.

.\scripts\Invoke-ALProjectBuild.ps1 -ProjectPath 'C:\vss-agent\2.337.0\_work\BCAppsBugFix\BCAppsBugFix\src\Apps\W1\Quality Management\test' -ProjectGroupRoot 'C:\vss-agent\2.337.0\_work\BCAppsBugFix\BCAppsBugFix\src\Apps\W1\Quality Management'

Result: passed, four projects compiled. Final build evidence: build-ae4c40f8c7954177b6a1d737ac8cfc72.json.

.\scripts\Publish-BCAppDeployment.ps1 -BuildResultPath 'C:\vss-agent\2.337.0\_work\_temp\bcfix-diagnostics-36690750368-1\source\package-staging\build-ae4c40f8c7954177b6a1d737ac8cfc72.json' -StateDirectory 'C:\Users\CLOUDT~1\AppData\Local\Temp\bc-fix-bug\BUG-531'

Result: deployed and exactly attested all four packages in dependency order.

.\scripts\Test-ALDeploymentReadiness.ps1 -BuildResultPath 'C:\vss-agent\2.337.0\_work\_temp\bcfix-diagnostics-36690750368-1\source\package-staging\build-ae4c40f8c7954177b6a1d737ac8cfc72.json' -StateDirectory 'C:\Users\CLOUDT~1\AppData\Local\Temp\bc-fix-bug\BUG-531' -Stage BeforeTests

Result: ready, schema version 2, all three proof flags true, including exact reachable local-artifact reattestation.

AL MCP test invocation: al_run_tests, codeunitId 139955, projectPath C:\vss-agent\2.337.0\_work\BCAppsBugFix\BCAppsBugFix\src\Apps\W1\Quality Management\test, serverUrl http://bcapps-36690750368-1, serverInstance BC, port 7049, tenant default, authentication UserPassword, with testMethods equal to the ten names below. Result: 10 passed, 0 failed, 0 skipped. The full module suite and manual UI scenarios were not run.

Automated Test Evidence

Test Pre-fix baseline Final
ActivationTriggerFindGenerationRule_ManualAndAuto_AutoRuleSearch PASS PASS
ActivationTriggerFindGenerationRule_ManualAndAuto_ManualRuleSearch PASS PASS
FindGenerationRule_ItemFilter PASS PASS
DemoBeansTrackedPurchase_ManualSelectsBeans FAIL PASS
DemoBeansTrackedPurchase_AutomaticSelectsBeans FAIL PASS
DemoBeansPurchase_OtherItemSelectsBeans FAIL PASS
DemoPurchase_NonBeansItemSelectsReceive PASS PASS
DemoBeansRule_HasPurchaseScopeAndPriority FAIL PASS
DemoBeansRule_RepeatedSeedingIsIdempotent FAIL PASS
DemoBeansRule_RepeatedSeedingPreservesCustomization FAIL PASS

The first three failing BEANS selection tests each reported:

Assert.AreEqual failed. Expected:<BEANS> (Text). Actual:<RECEIVE> (Text). The seeded purchase rule must select the template for the item category..

The three failing BEANS seed/scope/repeat tests each reported:

Assert.IsTrue failed. The demo seeder must create the BEANS rule.

Total Tests Run: 10 in the final run. All Tests Passing: Yes.

Exact responses are retained in bc-test-baseline-output-531-iteration-1.txt and bc-swe-test-output-531-iteration-1.txt in the run's per-bug state.

Validation Coverage

  • Three selected existing rule-resolution tests pass.
  • Seven new regression tests cover tracked WRB-1002, another BEANS item, non-BEANS fallback, manual/automatic resolution, scope/priority, idempotency, and customization preservation.
  • Full affected-project build and ordered deployment completed.
  • Independent critique: Accept, round 1, no suggestions.

Risk & compatibility

The change is limited to seeded demo configuration. The original helper signature, generic RECEIVE rule, and existing-record overwrite protection remain intact. No table schema, resolver algorithm, posting behavior, permissions, or transaction boundaries change.

The supplied working branch already contained seven infrastructure commits after origin/main before this task began, starting at 8a5adba63 and ending at 1e4fc454c. They affect 11 workflow/skill/support-script files and remain in the PR because this run was required to preserve the supplied branch without resetting or switching it. This run's only authored commit changes the five Quality Management files listed above. Infrastructure verification suites for those inherited changes were not rerun here.

Miapp Propagation

  • Layers propagated to: none; no propagated paths changed.
  • Files changed by propagation: 0; no conflicts kept as ours.
  • Prescribed Invoke-BugFixMiapp.ps1 Propagate and Verify both succeeded. Verify checked 16 files and reported no missing files.
  • Country-layer compilation is deferred to the Pull Request Build workflow.

AL Review

Status: Skipped - empty engine result. One round and one invocation. The vendored engine failed during pinned BCQuality skill-index construction because al-code-review.md referenced missing action skill microsoft/skills/review/al-performance-review.md; it produced no report.

Saved skip reason: Review report is absent or empty: C:\Users\CLOUDT~1\AppData\Local\Temp\bc-fix-bug\BUG-531\al-review\round-1\_review-report.json.

The approved Test-LocalReviewEvidence.ps1 -AllowEmptyReport classifier was independently rerun before PR creation and returned skipped-empty. Every available invocation artifact was archived; there were no earlier reports or known blocking findings. This is the skill's explicit V5 exception, not a clean review. No AL review verdict is available; findings and coverage are unknown. Engine metrics were not produced. No findings were applied and the independently accepted, green change set is unchanged.

Review Notes

Please review the category-specific demo rule and retained generic fallback, and account for the explicitly unavailable AL quality review and inherited infrastructure commits above.

Generated by the bc-fixbug skill.


Promoted from microsoft/BCAppsBugFix#580: https://github.com/microsoft/BCAppsBugFix/pull/580

Fixes AB#650223

@business-central-bug-fix-bot
business-central-bug-fix-bot Bot requested review from a team as code owners October 2, 2026 12:38
@business-central-bug-fix-bot business-central-bug-fix-bot Bot added the BugFixAgent Created by the BC bug-fix agent label Oct 2, 2026
@github-actions github-actions Bot added AL: Apps (W1) Add-on apps for W1 Team: SCM GitHub request for SCM area labels Oct 2, 2026
@github-actions github-actions Bot modified the milestone: Version 30.0 Oct 2, 2026
Comment thread src/Apps/W1/Quality Management/test/src/QltyTestsGenerationRule.Codeunit.al Outdated
@alexei-dobriansky

Copy link
Copy Markdown
Contributor

Good Sense Reviewer - Round 1

Recommendation: Request Changes

What this PR does

This change seeds a category-filtered BEANS Purchase Line rule at sort order 30, ahead of the generic RECEIVE rule at 40, and adds regression coverage. For normal item lines, the filter and ascending rule order correctly select BEANS for BEANS items and retain RECEIVE for other categories. However, the new rule can win when no item is resolved, and the added test dependency creates a third build stage without the required workflow update.

Problem-solution fit

Fit: Strong

The change targets the missing seeded rule and preserves the intended fallback for ordinary item lines. The two issues below must be corrected before the change is safe and buildable.

Suggestions

S1 (🔴 High): Skip BEANS when no item is resolved
The rule matcher accepts an item-filtered rule when the optional item is blank. Because this rule is evaluated before RECEIVE, a non-item Purchase Line can select BEANS; make filtered rules skip this case and add a regression test.

S2 (🔴 High): Regenerate workflows for the deeper build graph
This dependency makes the generated project graph require three build stages, while the workflows support only two, so initialization fails before compilation. Run Update AL-Go System Files and include the generated workflow changes.

Risk assessment and necessity

Risk: The runtime change is limited to demo configuration, but sort order 30 affects every Purchase Line rule search and can select BEANS when no item is resolved. Public APIs and event contracts are unchanged, and there is no BaseApp event dependency or country-layer impact. The new test dependency currently prevents the pull-request build from reaching compilation.

Necessity: The rule is required so demo bean receipts select the intended inspection template instead of the generic fallback. The scope is appropriate, but the unresolved-item behavior and generated build workflow must be corrected.


[AI-PR-REVIEW] version=1 promptVersion=4 system=github pr=12267 round=1 by=alexei-dobriansky at=2026-10-02T18:38:52Z lastSha=1ad6f1976100301e9544b69538330ffcccd36894 reviewKey=0d756ff57524898b88ce3aa688e136886fa466fd456cb2b26a3a085e1f951430 suggestions=S1@4953cf0a,S2@b2745b71

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
@alexei-dobriansky
alexei-dobriansky requested a review from a team October 6, 2026 14:43
@alexei-dobriansky

Copy link
Copy Markdown
Contributor

Addressed the remaining findings: af13ea7182 skips item-filtered rules when no item is resolved, adds non-item regression coverage, and commits before running the demo seeders. 271b58ef14 updates the generated workflow structure for three build stages. The branch was also merged with current main in 2182e13cf6.

@github-actions github-actions Bot added the Build: Automation Workflows and other setup in .github folder label Oct 6, 2026
Comment thread src/Apps/W1/Quality Management/test/src/QltyTestsGenerationRule.Codeunit.al Outdated
@alexei-dobriansky

Copy link
Copy Markdown
Contributor

Good Sense Reviewer - Round 2

Recommendation: Accept with Suggestions

What this PR does

The new commits make filtered generation rules skip unresolved items, add a regression test for the generic RECEIVE fallback, and update the generated workflows for a three-stage build graph. These changes address both previous blockers, and the BEANS-specific rule now applies only when the item matches its category filter. The remaining issues are analyzer warnings in the new demo and test code that currently keep the pull-request build red.

Status of previous suggestions
ID Title Status Author response
S1 Skip BEANS when no item is resolved Addressed The matcher now rejects filtered rules when the optional item is blank, and a regression test verifies RECEIVE is selected.
S2 Regenerate workflows for the deeper build graph Addressed The workflows now use depth 3 and include the required build stages and dependencies.
New observations (commits since round 1)

S3 (🟠 Moderate): Use bounded text for item filters
The new filter values produce AA0139 warnings because unbounded Text is passed to Text[2048]. Use Text[2048] variables or an explicit safe conversion so the pull-request build can pass.

S4 (🟠 Moderate): Avoid the LibraryInventory name collision
The new global LibraryInventory has the same name as two existing local variables, which produces AA0198 warnings. Rename the global or the local variables so the pull-request build can pass.

Risk assessment and necessity

Risk: The matcher change affects every item-filtered generation rule, but the new condition preserves generic rules and explicitly covers the unresolved-item fallback. Public APIs and event contracts are unchanged. The current W1 build fails only on the four new analyzer warnings described above, so these should be cleared before merge.

Necessity: The BEANS rule is required so category-specific coffee purchases select BEANS before the generic RECEIVE rule. The matcher guard and workflow regeneration are also necessary to make that configuration safe and buildable; the scope remains focused on the reported demo-data defect and its validation.


[AI-PR-REVIEW] version=1 promptVersion=4 system=github pr=12267 round=2 by=alexei-dobriansky at=2026-10-06T18:51:03Z lastSha=271b58ef148efc8b053200050e41735da6627f26 reviewKey=fdf3d5323fa1cf194f3fd3c7f4ea7b4b897eff3268594571963adbabcf7c9450 suggestions=S1@4953cf0a:addressed,S2@b2745b71:addressed,S3@9857f06b:new,S4@a107be5c:new parentRound=1

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
@alexei-dobriansky

Copy link
Copy Markdown
Contributor

Addressed the remaining analyzer and review findings in 7e05285e06: bounded both item-filter values, removed the LibraryInventory name collisions, made BeansDesc internal, replaced Count with IsEmpty, and marked the seeder tests AutoCommit.

@alexei-dobriansky

Copy link
Copy Markdown
Contributor

Good Sense Reviewer - Round 3

Recommendation: Request Changes

What this PR does

The new commit bounds the item-filter text, removes the test variable name collision, and allows the demo seeder tests to commit. The focused generation-rule tests now pass, and the earlier runtime and workflow findings are addressed. However, the test app now depends on a W1-only demo package while it is still compiled in regional app jobs, so the PR does not build in RU.

Status of previous suggestions
ID Title Status Author response
S1 Skip BEANS when no item is resolved Addressed Filtered rules now require a resolved item, and the fallback test passes.
S2 Regenerate workflows for the deeper build graph Addressed The workflows now include the third build stage and its dependencies.
S3 Use bounded text for item filters Addressed The new filter values use Text[2048] with an explicit bounded copy.
S4 Avoid the LibraryInventory name collision Addressed The existing local variables now have distinct names.
New observations (commits since round 2)

S5 (🔴 High): Keep demo-only tests out of regional builds
The added dependency is available only in the W1 build, but Quality Management-Tests is also compiled for regional app jobs. The RU build now fails with AL1022 because the demo package is missing; move these tests to a W1-only demo test app or otherwise keep this dependency out of regional builds.

Risk assessment and necessity

Risk: The runtime rule change is narrow and the focused tests pass in W1. The new test-app dependency still breaks the regional build graph, so this branch cannot pass the required app compilation until the tests are placed in a W1-only project or the dependency is removed from regional builds.

Necessity: The BEANS rule and its regression coverage are needed to preserve the category-specific demo behavior and the generic RECEIVE fallback. The test placement must change without weakening that coverage.


[AI-PR-REVIEW] version=1 promptVersion=4 system=github pr=12267 round=3 by=alexei-dobriansky at=2026-10-07T00:44:35Z lastSha=7e05285e06d95ce75f67cc7df986cf3b2f8daa12 reviewKey=4497ad4df76211ef2ab42108d481518306748ae47453d84e62db2df650a01d15 suggestions=S1@4953cf0a:addressed,S2@b2745b71:addressed,S3@9857f06b:addressed,S4@a107be5c:addressed,S5@a7b35460:new parentRound=2

@alexei-dobriansky alexei-dobriansky left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Clean it up

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
@github-actions github-actions Bot removed the Build: Automation Workflows and other setup in .github folder label Oct 8, 2026
end;

procedure InsertQualityInspectionGenRule(EntryNo: Integer; SortOrder: Integer; Intent: Enum "Qlty. Gen. Rule Intent"; TemplateCode: Code[20]; SourceTableNo: Integer; ConditionFilter: Text[400]; Description: Text[100]; ActivationTrigger: Enum "Qlty. Gen. Rule Act. Trigger")
begin

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$\textbf{🟡\ Medium\ Severity\ —\ Style}$

The changed public overloads of the demo library procedure InsertQualityInspectionGenRule do not have XML documentation. Add a summary, one param tag for each parameter, and a return tag when applicable so callers can understand the public helper contract.

Knowledge:

👍 useful · ❤️ especially valuable · 👎 wrong - reply with why · AL review agent v1.49.6

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
@alexei-dobriansky

Copy link
Copy Markdown
Contributor

The post-YAML-revert Initialization failure was related to this PR: the Quality Management test app dependency on the Demo Dataset required build depth 3. Fixed in ff6d64cb26 without workflow changes by removing that dependency and seeding the equivalent template/rule fixture directly in the existing test app. The tests no longer call committing demo codeunits, so the temporary AutoCommit attributes were also removed.

@alexei-dobriansky

Copy link
Copy Markdown
Contributor

Good Sense Reviewer - Round 4

Recommendation: Accept with Suggestions

What this PR does

The new commits remove unrelated workflow changes and the W1-only test-app dependency, restoring regional compilation. The product change still seeds a BEANS purchase rule at sort order 30 with a category filter, preserves RECEIVE at sort order 40, and prevents item-filtered rules from matching when no item is resolved. The runtime logic and helper overload are coherent, but the replacement regression tests now recreate the demo setup locally instead of executing the production seeder.

Status of previous suggestions
ID Title Status Author response
S1 Skip BEANS when no item is resolved Addressed Filtered rules now require a resolved item.
S2 Regenerate workflows for the deeper build graph Addressed The demo dependency and extra build-graph depth were removed.
S3 Use bounded text for item filters Addressed Generated filter values use Text[2048] and an explicit bounded copy.
S4 Avoid the LibraryInventory name collision Addressed The conflicting local variables have distinct names.
S5 Keep demo-only tests out of regional builds Addressed The W1-only dependency was removed, and regional app builds including RU pass.
New observations (commits since round 3)

S6 (🟠 Moderate): Tests bypass the production demo seeder
These tests recreate the rules instead of running Create QM Generation Rule. They can pass if the production seeder omits BEANS or uses the wrong filter, IDs, or priority. Add coverage in a test app that can execute the production demo seeder, or provide a testable production seam.

Risk assessment and necessity

Risk: The production behavior is narrow, the original helper signature remains compatible, and regional compilation is restored. The remaining risk is that the tests will not detect a regression in the actual demo seeder.

Necessity: The BEANS rule is needed because tracked BEANS items otherwise select the generic RECEIVE rule. The production scope is appropriate, but direct coverage of the seeded configuration should be retained.


[AI-PR-REVIEW] version=1 promptVersion=4 system=github pr=12267 round=4 by=alexei-dobriansky at=2026-10-08T12:48:20.1193325Z lastSha=ff6d64cb26f84043bd697fede55eb1b4a64a2073 reviewKey=f4750489ce7fdd76cf2d0e6a6700674e9c134250d40102979a007e0dbdc4b209 suggestions=S1@4953cf0a:addressed,S2@b2745b71:addressed,S3@9857f06b:addressed,S4@a107be5c:addressed,S5@a7b35460:addressed,S6@52e23ffa:new parentRound=3

@alexei-dobriansky alexei-dobriansky self-assigned this Oct 8, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

S1 - Restore direct regression coverage for the production demo seeder (High confidence)

The latest test change removed the Demo Data dependency and now recreates templates and generation rules through local test helpers. None of the eight tests executes Create QM Generation Rule or the new Contoso Quality Management.InsertQualityInspectionGenRule(..., ItemFilter) overload. The suite therefore remains green if the production seeder omits BEANS, passes the wrong category filter or priority, or the overload drops Item Filter - precisely the root defect and both production surfaces changed by this PR.

Please move the seed-specific assertions to a W1-only test project that can run the real seeder, or extract a production seam that the regional test app can invoke without taking a W1-only package dependency. Keep the local matcher tests for BEANS, non-BEANS, and non-item resolution. Please also update the PR description because it currently says the tests exercise the actual demo configuration and still lists a removed test dependency.

The rule-matching correction itself is coherent and covers the unresolved-item fallback. All 170 checks completed: 168 successful and 2 skipped. The unresolved XML-documentation thread is nonblocking.

@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Stale Status Check Deleted

The Pull Request Build workflow run for this PR was older than 72 hours and has been deleted.

📋 Why was it deleted?

Status checks that are too old may no longer reflect the current state of the target branch. To ensure this PR is validated against the latest code and passes up-to-date checks, a fresh build is required.


🔄 How to trigger a new status check:

  1. 📤 Push a new commit to the PR branch, or
  2. 🔁 Close and reopen the PR

This will automatically trigger a new Pull Request Build workflow run.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 83f7893f-a0aa-4f98-99e6-7d8176e8f906
InsertQualityInspectionGenRule(EntryNo, SortOrder, Intent, TemplateCode, SourceTableNo, ConditionFilter, Description, ActivationTrigger, '');
end;

procedure InsertQualityInspectionGenRule(EntryNo: Integer; SortOrder: Integer; Intent: Enum "Qlty. Gen. Rule Intent"; TemplateCode: Code[20]; SourceTableNo: Integer; ConditionFilter: Text[400]; Description: Text[100]; ActivationTrigger: Enum "Qlty. Gen. Rule Act. Trigger"; ItemFilter: Text[2048])

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$\textbf{🟡\ Medium\ Severity\ —\ Style}$

The new public InsertQualityInspectionGenRule overload on the Contoso library codeunit has no XML documentation. Add a meaningful

and one entry for each parameter so callers can understand the procedure's behavior and the ItemFilter precondition.

Knowledge:

👍 useful · ❤️ especially valuable · 👎 wrong - reply with why · AL review agent v1.50.6

InsertDemoGenerationRule(4, 40, ReceiveTemplateCodeTok, ReceiveTemplateDescTok, '');
end;

local procedure InsertDemoTemplate(TemplateCode: Code[20]; TemplateDescription: Text[100])

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$\textbf{🟠\ High\ Severity\ —\ Testing}$

The new demo tests build their own templates and generation rules in InsertDemoTemplate and InsertDemoGenerationRule instead of invoking the changed demo-data codeunits. This hand-rolled fixture duplicates the production defaults, so the tests can pass while the actual demo seeding is broken or diverges from the fixture. Seed the fixture through CreateQMInspTemplateHdr/CreateQMGenerationRule (or a maintained test-library wrapper) and assert the records produced by that code.

Knowledge:

👍 useful · ❤️ especially valuable · 👎 wrong - reply with why · AL review agent v1.50.6

QltyInspectionGenRule.DeleteAll();
end;

local procedure SeedDemoGenerationRules()

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$\textbf{🟡\ Medium\ Severity\ —\ Testing}$

The tests labeled as demo-generation tests recreate the BEANS and RECEIVE rules in the local SeedDemoGenerationRules fixture instead of invoking the changed Create QM Generation Rule demo codeunit. They can therefore pass while the production demo seeder is broken; invoke the production seeder and assert its resulting records, keeping only minimal test-only data setup that the seeder does not provide.

👍 useful · ❤️ especially valuable · 👎 wrong - reply with why · AL review agent v1.50.6

@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Stale Status Check Deleted

The Pull Request Build workflow run for this PR was older than 72 hours and has been deleted.

📋 Why was it deleted?

Status checks that are too old may no longer reflect the current state of the target branch. To ensure this PR is validated against the latest code and passes up-to-date checks, a fresh build is required.


🔄 How to trigger a new status check:

  1. 📤 Push a new commit to the PR branch, or
  2. 🔁 Close and reopen the PR

This will automatically trigger a new Pull Request Build workflow run.

This branch had an error being deployed

1 failed (outdated) and 1 active (outdated) deployments
triage — ff6d64cb Deployed Oct 15, 2026 by alexei-dobriansky via Classify team ownership #8052
Official-Build — 2182e13c Deployed Oct 6, 2026 by alexei-dobriansky
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AL: Apps (W1) Add-on apps for W1 BugFixAgent Created by the BC bug-fix agent Team: SCM GitHub request for SCM area

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants