Skip to content

feat(workbench): cover Workbench Jobs and Background Jobs #302

@samcofer

Description

@samcofer

Background

A Posit customer mapped their UAT test plan against VIP and identified Workbench Jobs as a feature with no coverage today. Both Workbench Jobs (run on a separate Kubernetes pod) and Background Jobs (run in the same session) are first-class Workbench features that customers exercise during acceptance — there's nothing deployment-specific about them.

What's missing

src/vip_tests/workbench/ has no test_jobs.feature. The existing tests cover session launch, suspend/resume, and capacity, but never submit a script as a job.

Proposed scenarios

@workbench
Feature: Workbench Jobs and Background Jobs

  Scenario: User can submit a Workbench Job from RStudio Pro
    Given the user is logged in to Workbench
    When the user starts a new RStudio session
    And the user submits a short R script as a Workbench Job
    Then the job reaches Completed state
    And the job log contains the expected output
    And the session is cleaned up

  Scenario: User can submit a Background Job from RStudio Pro
    Given the user is logged in to Workbench
    When the user starts a new RStudio session
    And the user submits a short R script as a Background Job
    Then the Background Jobs pane shows the job as Completed
    And the session is cleaned up

Acceptance criteria

  • A new src/vip_tests/workbench/test_jobs.feature with both scenarios, tagged @workbench.
  • Step definitions in src/vip_tests/workbench/test_jobs.py that drive the RStudio Workbench Jobs / Background Jobs UI via Playwright.
  • A short bundled test R script (e.g. Sys.sleep(2); cat("hello from job\n")) shipped with the test, written into the session's working directory.
  • Cleanup: any leftover job artifacts removed.

Notes

  • Workbench Jobs use Launcher infrastructure, so this scenario also indirectly verifies the Launcher is functional — a useful side effect.
  • This depends on the in-session execution primitive (separate issue) only for writing the script file into the session; otherwise it's standalone.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions