GitHub surfaces approachable repository work through the good first issue label. Neo currently has no open issue carrying that label, so this ticket creates one deliberately bounded, self-contained entry point outside the v13.2 release work.
[!IMPORTANT]
Reserved for first-time Neo.mjs contributors. The Neo maintainer team will not claim, edit, or implement this ticket through 2026-07-20. A first-time contributor may claim it immediately; contributor questions and PR reviews remain welcome during the reservation window.
Please comment before starting. A maintainer will assign the ticket to one contributor to avoid duplicate work.
Problem
Neo.util.Array is a foundational helper used throughout Neo's VDOM, observable, component, layout, grid, selection, and docking code. Its public helpers mutate arrays, preserve or change ordering, prevent duplicate references, and implement set-like operations, but the class has no focused unit spec.
These behaviors are small enough to test directly and important enough that an accidental semantic change can fan out across many consumers.
Architectural reality
Runtime source: src/util/Array.mjs
Canonical test destination: test/playwright/unit/util/Array.spec.mjs
Established sibling pattern: test/playwright/unit/util/Json.spec.mjs, String.spec.mjs, and Rectangle.spec.mjs
Structural pre-flight: fast-path; the proposed spec exactly matches the existing test/playwright/unit/util/ sibling pattern.
This is test-only work; no new runtime abstraction or directory is needed.
Fix
Add one focused Playwright unit spec for the existing Neo.util.Array API. Pin the current documented/runtime behavior without changing src/util/Array.mjs.
Contract ledger
Target surface
Source of authority
Existing behavior to pin
Fallback / edge case
Docs
Evidence
add(), unshift()
src/util/Array.mjs JSDoc + implementation
Accept a scalar or array, mutate and return the original array, and skip items already present by reference
Add test/playwright/unit/util/Array.spec.mjs using the existing util-spec setup/import pattern.
Cover all public helpers: add, difference, hasItem, insert, intersection, move, remove, removeAdd, toggle, union, and unshift.
Assert that mutating helpers return the original array reference.
Cover scalar and array inputs where supported.
Cover duplicate prevention and object reference identity.
Cover representative ordering behavior for insert, move, and unshift.
Cover default and explicit branches of toggle().
Assert that set-like helpers do not mutate their input arrays.
Keep the change test-only. If documented behavior and runtime behavior appear to disagree, stop and ask on this ticket before changing src/util/Array.mjs.
Run the focused spec:
npm run test-unit -- test/playwright/unit/util/Array.spec.mjs
Run the complete unit suite:
npm run test-unit
Out of scope
Refactoring Neo.util.Array
Adding deep-equality semantics
Changing ordering, duplicate, or mutation behavior
Broad utility-suite cleanup
Any v13.2 release, Agent OS, Fleet Manager, docking-feature, or Golden Path work
Avoided traps
Do not run default npx playwright test; Neo requires its custom unit configuration.
Import src/Neo.mjs and src/core/_export.mjs as the sibling specs do.
Do not replace the helpers with native alternatives in runtime consumers.
Do not change runtime behavior merely to make a test easier.
Live latest-open, exact-path, Knowledge Base, local issue/discussion, and recent A2A claim sweeps were refreshed immediately before creation at 2026-07-13T03:15:24.013Z; no equivalent ticket or active lane was found.
Decision Record impact
None. This ticket pins an existing public utility contract and introduces no architectural decision.
Hi! I'm interested in working on this issue as my first contribution to Neo.mjs. I've read the issue description and would like to take it on. Could you please assign it to me? Thanks!
2026-07-13T10:00:25Z @neo-gpt-emmy assigned to @msranjana
@neo-gpt-emmy - 2026-07-13T10:00:28Z
Thanks for stepping up, @msranjana — I verified that this is your first Neo.mjs contribution and assigned the issue to you.
I strongly recommend starting with Neo's unit-testing agent skill at .agents/skills/unit-test/SKILL.md. Neo uses a custom Playwright unit-test layout, setup sequence, and focused-run command; generic Playwright assumptions are a common source of avoidable friction.
Please keep the PR test-only as specified. If the documented contract and runtime behavior appear to disagree, pause and ask here before changing src/util/Array.mjs. When opening the PR, link it with Closes #15124 and include the focused-spec and full-suite results.
Context
GitHub surfaces approachable repository work through the
good first issuelabel. Neo currently has no open issue carrying that label, so this ticket creates one deliberately bounded, self-contained entry point outside the v13.2 release work.Problem
Neo.util.Arrayis a foundational helper used throughout Neo's VDOM, observable, component, layout, grid, selection, and docking code. Its public helpers mutate arrays, preserve or change ordering, prevent duplicate references, and implement set-like operations, but the class has no focused unit spec.These behaviors are small enough to test directly and important enough that an accidental semantic change can fan out across many consumers.
Architectural reality
src/util/Array.mjstest/playwright/unit/util/Array.spec.mjstest/playwright/unit/util/Json.spec.mjs,String.spec.mjs, andRectangle.spec.mjstest/playwright/unit/util/sibling pattern.Fix
Add one focused Playwright unit spec for the existing
Neo.util.ArrayAPI. Pin the current documented/runtime behavior without changingsrc/util/Array.mjs.Contract ledger
add(),unshift()src/util/Array.mjsJSDoc + implementationArray.spec.mjsinsert(),move()src/util/Array.mjs;src/vdom/Helper.mjsexisting-item commentremove(),removeAdd(),toggle()src/util/Array.mjsJSDoc + implementationtoggle(..., add)overrides inferred membershiphasItem()src/util/Array.mjsJSDoc + implementationdifference(),intersection(),union()src/util/Array.mjsJSDoc + implementationunion()removes duplicatesAcceptance criteria
test/playwright/unit/util/Array.spec.mjsusing the existing util-spec setup/import pattern.add,difference,hasItem,insert,intersection,move,remove,removeAdd,toggle,union, andunshift.insert,move, andunshift.toggle().src/util/Array.mjs.npm run test-unit -- test/playwright/unit/util/Array.spec.mjsnpm run test-unitOut of scope
Neo.util.ArrayAvoided traps
npx playwright test; Neo requires its custom unit configuration.src/Neo.mjsandsrc/core/_export.mjsas the sibling specs do.Prior art and duplicate sweep
Decision Record impact
None. This ticket pins an existing public utility contract and introduces no architectural decision.
Origin Session ID:
f95e01ff-ba36-409a-98af-573263fab247