From b7638b8fffe78ade657f361cadc08dffc8c10acf Mon Sep 17 00:00:00 2001 From: Yong He Date: Mon, 27 Jun 2022 15:36:00 -0700 Subject: Language server fixes and improvements (#2304) * Language server: Inlay hints. * Signature help for base exprs that is not a declref. * Fix checking of jvp operator. * Fix. * Add clang-format based auto formatting. * Fix clang error. * Fix clang-format discovery logic. * Fine tune auto formatting and completion experience. * Update macos workflow. * Fixes to configurations. * Fix parser recovery to trigger completion for index exprs. * Typo fix. Co-authored-by: Yong He --- tools/slang-test/slang-test-main.cpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'tools') diff --git a/tools/slang-test/slang-test-main.cpp b/tools/slang-test/slang-test-main.cpp index ea5ada4b0..355f28a23 100644 --- a/tools/slang-test/slang-test-main.cpp +++ b/tools/slang-test/slang-test-main.cpp @@ -1716,6 +1716,23 @@ TestResult runLanguageServerTest(TestContext* context, TestInput& input) if (!_areResultsEqual(input.testOptions->type, expectedOutput, actualOutput)) { + if (expectedOutput.startsWith("CONTAINS")) + { + List words; + List expectedLines; + StringUtil::calcLines(expectedOutput.getUnownedSlice(), expectedLines); + if (expectedLines.getCount() >= 1) + { + StringUtil::split(expectedLines[0], ' ', words); + if (words.getCount() >= 2) + { + if (actualOutput.contains(words[1].trim())) + { + return result; + } + } + } + } context->getTestReporter()->dumpOutputDifference(expectedOutput, actualOutput); result = TestResult::Fail; } -- cgit v1.2.3