Skip to content

Commit

Permalink
Make hover e2e tests fixture messages more generic (#934)
Browse files Browse the repository at this point in the history
* make messages more generic for assertion to avoid failures because of md syntax

* update testing with expect
  • Loading branch information
priyamsahoo committed Jun 28, 2023
1 parent fd072bf commit 33567bd
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
12 changes: 4 additions & 8 deletions test/testScripts/hover/testWithEE.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,7 @@ export function testHoverEE(): void {
it("should hover over builtin module option", async () => {
await testHover(docUri1, new vscode.Position(6, 9), [
{
contents: [
"The customized message that is printed. If omitted, prints a generic message.",
],
contents: ["customized message"],
},
]);
});
Expand All @@ -74,25 +72,23 @@ export function testHoverEE(): void {
it("should hover over collection module name present in EE (ansible.posix.patch)", async () => {
await testHover(docUri1, new vscode.Position(9, 7), [
{
contents: ["Apply patch files using the GNU patch tool."],
contents: ["GNU patch"],
},
]);
});

it("should hover over collection module option present in EE (ansible.posix.patch -> src)", async () => {
await testHover(docUri1, new vscode.Position(10, 9), [
{
contents: [
"Path of the patch file as accepted by the GNU patch tool.",
],
contents: ["GNU patch"],
},
]);
});

it("should hover over collection module option present in EE (ansible.posix.patch -> dest)", async () => {
await testHover(docUri1, new vscode.Position(11, 9), [
{
contents: ["Path of the file on the remote machine to be patched."],
contents: ["remote machine"],
},
]);
});
Expand Down
4 changes: 1 addition & 3 deletions test/testScripts/hover/testWithoutEE.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,7 @@ export function testHoverWithoutEE(): void {
it("should hover over builtin module option", async () => {
await testHover(docUri1, new vscode.Position(6, 9), [
{
contents: [
"The customized message that is printed. If omitted, prints a generic message.",
],
contents: ["customized message"],
},
]);
});
Expand Down

0 comments on commit 33567bd

Please sign in to comment.