Skip to content

Move the headless smoke test into the repo #131

Closed

Description

@CatarinaGamboa

Why: a working smoke test exists outside the repo (it opens a failing Java file in headless VS Code, runs LiquidJava: Verify, and checks for the refinement error). It checks the main feature end to end but only runs by hand on one machine.

What:

  • Add @vscode/test-cli, @vscode/test-electron and a .vscode-test.mjs.
  • Put the fixture in client/test-fixtures/failing/src/main/java/. It must be outside client/src because of the src path rule in JUnit tests for the language server #129, and each fixture needs its own workspace because the server only reads the first workspace folder.
  • Test that the extension activates, ready resolves, and Verify produces the expected Refinement Error diagnostic (waiting on onDiagnostics, not sleeping).
  • Add an integration job to test.yml, running on every branch push like the rest (one fixture on stable should take a few minutes):
    • setup-java pinned to 21, with JAVA_HOME set (the client checks JAVA_HOME first, and the server needs Java 20 or newer)
    • xvfb-run -a npm test
    • a 120s Mocha timeout for the first verify (cold JVM, Spoon and z3)
    • VS Code logs uploaded as an artifact on failure

References:

Metadata

Metadata

Assignees

No one assigned

    Labels

    testingTesting related

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions