Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests implementation liberty-ls support in server.xml for diagnostic and quickfix #377

Open
wants to merge 35 commits into
base: main
Choose a base branch
from

Conversation

SuparnaSuresh
Copy link
Contributor

@SuparnaSuresh SuparnaSuresh commented Nov 18, 2024

Fixes #370 Fixes #434

@SuparnaSuresh SuparnaSuresh self-assigned this Dec 9, 2024
*/
export async function removeConfigDir(projectPath: string): Promise<void> {
try {
await fs.accessSync(projectPath);

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The following methods are synchronous methods. await has no effect on them.
accessSync, readdirSync, lstatSync, unlinkSync, rmdirSync

utils.copyConfig(path.join(utils.getGradleProjectPath(), 'src', 'main', 'liberty', 'config'), path.join(utils.getGradleProjectPath(), 'src', 'main', 'liberty', 'config2'));
});

it('Should coppy content of server.xml', async () => {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo copy

editor = await new EditorView().openEditor('server.xml') as TextEditor;
actualSeverXMLContent = await editor.getText();

assert(actualSeverXMLContent.length !== 0, 'Content of server.xml is not in coppied.');

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo copied. check for similar typos

const qckFixPopupLink = await hoverTxt.findElement(By.xpath("//*[contains(text(), 'Quick Fix')]"));
await qckFixPopupLink.click();

const hoverTaskBar = await editor.findElement(By.className('context-view monaco-component bottom left fixed'));

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is hoverTaskBar required? There is no actionable task performed by hoverTaskBar. It seems that removing below two lines does not affect the test. Kindly confirm.

Copy link

@gilbysunil14 gilbysunil14 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good, but I have some comments. Please check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Tests liberty-ls support in server.xml for quickfix Tests liberty-ls support in server.xml for diagnostic
2 participants