-
Notifications
You must be signed in to change notification settings - Fork 162
Expand file tree
/
Copy pathjava-single-file.yaml
More file actions
69 lines (61 loc) · 2.99 KB
/
Copy pathjava-single-file.yaml
File metadata and controls
69 lines (61 loc) · 2.99 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
# Test Plan: Java Single File (from vscode-java-pack.wiki)
#
# Source: wiki Test-Plan.md "Single file" scenario
# Verify: Create a single Java file in an empty folder → LS ready → editing experience works
#
# Prerequisites:
# - JDK installed and available
#
# Usage: autotest run test-plans/java-single-file.yaml
name: "Java Single File — Single File Editing Experience"
description: |
Corresponds to the Single file scenario in the wiki Test Plan:
Open a Java file in an empty folder, verify the language server starts normally,
and verify editing experience including snippets, diagnostics, and completion works correctly.
setup:
extension: "redhat.java"
extensions:
- "vscjava.vscode-java-pack"
vscodeVersion: "stable"
# Use simple-app's App.java as the single file scenario
# The framework will automatically copy to a temp directory
workspace: "../../vscode-java/test/resources/projects/eclipse/simple-app"
timeout: 60
steps:
# ── Step 1: Wait for LS ready ────────────────────────────────
# wiki: "Check the language server is initialized, and the
# status bar icon is 👍 after that."
- id: "ls-ready"
action: "waitForLanguageServer"
verify: "Java extension has activated for the single-file workspace; no error notifications are visible"
# waitForLanguageServer is authoritative — skip LLM screenshot re-check.
skipLlmVerify: true
timeout: 120
# ── Step 2: Open Java file ──────────────────────────────
- id: "open-app"
action: "open file App.java"
verify: "App.java file is open in the editor"
waitBefore: 5
timeout: 10
# ── Step 3: Verify code completion ────────────────────────────────
# verifyCompletion.notEmpty is the deterministic ground truth; the
# verify text is lenient because on slower CI the popup may still show
# "Loading..." while items are already in the list.
- id: "verify-completion"
action: "triggerCompletionAt endOfMethod"
verify: "Code completion has been triggered in App.java; the IntelliSense popup is being rendered (the language server may briefly show a 'Loading...' indicator while computing suggestions on a cold cache — this is a valid intermediate state since the deterministic verifyCompletion.notEmpty asserts the LS produced completion items)"
verifyCompletion:
notEmpty: true
waitBefore: 8
# Retry once on cold-cache "Loading..." LLM downgrades.
retries: 1
# ── Step 4: Verify basic editing ────────────────────────────────
- id: "goto-main"
action: "goToLine 6"
verify: "Cursor moved to main method"
- id: "goto-end"
action: "goToEndOfLine"
- id: "type-code"
action: "typeInEditor \n System.out.println(\"Hello\");"
verifyEditor:
contains: "System.out.println"