Skip to content

Scenario: Verify lint passes with @nx/enforce-module-boundaries after file moves #344

@LayZeeDK

Description

@LayZeeDK

Scenario Purpose

Add an end-to-end scenario to the test suite specified in #319 that:

  • Moves files between library and application projects in a workspace.
  • Ensures all affected projects pass linting when the @nx/enforce-module-boundaries rule is enabled.
  • Validates that project boundaries are respected after the move (no improper imports).

Implementation Plan

  1. Update test harness to enable @nx/enforce-module-boundaries in the workspace lint configuration (e.g., workspace tslint.json or equivalent for ESLint).
  2. For each planned file move scenario (lib→lib, app→lib, lib→app, etc.):
    • Perform the move using existing scenario helpers.
    • Run nx lint <project> on all affected projects post-move.
    • Capture and assert success (exit code 0, no errors).
  3. Add allocated projects to the shared workspaces to avoid shared state.
  4. Follow structure of other scenario tests.
  5. Verify that the setup can detect lint rule violations.

Acceptance Criteria

  • All file moves performed in the scenario result in passing lint for every involved project with @nx/enforce-module-boundaries enabled.
  • Assertions capture correct moves.
  • Scenario is included in orchestrator spec for CI execution and measurable via stdio: 'inherit'.
  • Temp workspace teardown handled reliably post-test.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions