Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ related_information[0].location.range: Range { start: Position { line: 1, charac
severity: Some(Warning)
source: Some("oxc")
tags: None

fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 0, character: 1 }, end: Position { line: 1, character: 5 } } })


code: "eslint(no-debugger)"
code_description.href: "https://oxc.rs/docs/guide/usage/linter/rules/eslint/no-debugger.html"
Expand All @@ -24,7 +25,8 @@ related_information[0].location.range: Range { start: Position { line: 10, chara
severity: Some(Warning)
source: Some("oxc")
tags: None

fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 0, character: 3 }, end: Position { line: 1, character: 7 } } })


code: "eslint(no-debugger)"
code_description.href: "https://oxc.rs/docs/guide/usage/linter/rules/eslint/no-debugger.html"
Expand All @@ -36,7 +38,8 @@ related_information[0].location.range: Range { start: Position { line: 14, chara
severity: Some(Warning)
source: Some("oxc")
tags: None

fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 0, character: 3 }, end: Position { line: 1, character: 7 } } })


code: "eslint(no-debugger)"
code_description.href: "https://oxc.rs/docs/guide/usage/linter/rules/eslint/no-debugger.html"
Expand All @@ -48,3 +51,4 @@ related_information[0].location.range: Range { start: Position { line: 18, chara
severity: Some(Warning)
source: Some("oxc")
tags: None
fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 0, character: 3 }, end: Position { line: 1, character: 7 } } })
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ related_information[0].location.range: Range { start: Position { line: 1, charac
severity: Some(Warning)
source: Some("oxc")
tags: None
fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 1, character: 0 }, end: Position { line: 1, character: 9 } } })
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ related_information[0].location.range: Range { start: Position { line: 1, charac
severity: Some(Error)
source: Some("oxc")
tags: None
fixed: None
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ related_information[0].location.range: Range { start: Position { line: 1, charac
severity: Some(Error)
source: Some("oxc")
tags: None
fixed: None
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ related_information[0].location.range: Range { start: Position { line: 1, charac
severity: Some(Error)
source: Some("oxc")
tags: None
fixed: None
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ related_information[0].location.range: Range { start: Position { line: 0, charac
severity: Some(Error)
source: Some("oxc")
tags: None
fixed: None
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ related_information: None
severity: Some(Error)
source: Some("oxc")
tags: None
fixed: None
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ related_information[0].location.range: Range { start: Position { line: 3, charac
severity: Some(Error)
source: Some("oxc")
tags: None

fixed: None


code: "typescript-eslint(no-non-null-asserted-optional-chain)"
code_description.href: "https://oxc.rs/docs/guide/usage/linter/rules/typescript/no-non-null-asserted-optional-chain.html"
Expand All @@ -27,7 +28,8 @@ related_information[1].location.range: Range { start: Position { line: 11, chara
severity: Some(Error)
source: Some("oxc")
tags: None

fixed: Some(FixedContent { message: Some("Delete this code."), code: "", range: Range { start: Position { line: 11, character: 21 }, end: Position { line: 11, character: 22 } } })


code: "None"
code_description.href: "None"
Expand All @@ -39,3 +41,4 @@ related_information[0].location.range: Range { start: Position { line: 11, chara
severity: Some(Hint)
source: Some("oxc")
tags: None
fixed: None
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ related_information[0].location.range: Range { start: Position { line: 1, charac
severity: Some(Error)
source: Some("oxc")
tags: None

fixed: None


code: "eslint(no-useless-escape)"
code_description.href: "https://oxc.rs/docs/guide/usage/linter/rules/eslint/no-useless-escape.html"
Expand All @@ -24,3 +25,4 @@ related_information[0].location.range: Range { start: Position { line: 0, charac
severity: Some(Error)
source: Some("oxc")
tags: None
fixed: Some(FixedContent { message: Some("Replace `\\/` with `/`."), code: "/", range: Range { start: Position { line: 0, character: 16 }, end: Position { line: 0, character: 18 } } })
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,4 @@ related_information[0].location.range: Range { start: Position { line: 1, charac
severity: Some(Warning)
source: Some("oxc")
tags: None
fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 0, character: 2 }, end: Position { line: 1, character: 2 } } })
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ related_information[0].location.range: Range { start: Position { line: 5, charac
severity: Some(Warning)
source: Some("oxc")
tags: None

fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 0, character: 5 }, end: Position { line: 1, character: 2 } } })


code: "eslint(no-debugger)"
code_description.href: "https://oxc.rs/docs/guide/usage/linter/rules/eslint/no-debugger.html"
Expand All @@ -24,3 +25,4 @@ related_information[0].location.range: Range { start: Position { line: 10, chara
severity: Some(Warning)
source: Some("oxc")
tags: None
fixed: Some(FixedContent { message: Some("Remove the debugger statement"), code: "", range: Range { start: Position { line: 2, character: 1 }, end: Position { line: 2, character: 10 } } })
4 changes: 3 additions & 1 deletion crates/oxc_language_server/src/tester.rs
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ fn get_snapshot_from_report(report: &DiagnosticReport) -> String {
let severity = report.diagnostic.severity;
let source = &report.diagnostic.source;
let tags = &report.diagnostic.tags;
let fixed = &report.fixed_content;

format!(
r"
Expand All @@ -79,7 +80,8 @@ range: {range:?}
severity: {severity:?}
source: {source:?}
tags: {tags:?}
"
fixed: {fixed:?}
"
)
}

Expand Down
Loading