Files
sourcekit-lsp/Sources/LanguageServerProtocol/Requests/WorkspaceTestsRequest.swift
Alex Hoppen 65b9505081 Return workspace tests in a hierarchical format
This ways the client doesn’t need to create a hierarchical structure using the container names. It is also more flexible and allows nesting of test suites + the addition of labels and tags for swift-testing.

The data structure for `TestItem` has been heavily inspired by VS Code’s `TestItem` for the test explorer, which should make it fairly straightforward to integrate these results into the VS Code test explorer.
2024-04-05 20:16:06 -07:00

22 lines
834 B
Swift

//===----------------------------------------------------------------------===//
//
// This source file is part of the Swift.org open source project
//
// Copyright (c) 2014 - 2023 Apple Inc. and the Swift project authors
// Licensed under Apache License v2.0 with Runtime Library Exception
//
// See https://swift.org/LICENSE.txt for license information
// See https://swift.org/CONTRIBUTORS.txt for the list of Swift project authors
//
//===----------------------------------------------------------------------===//
/// A request that returns symbols for all the test classes and test methods within the current workspace.
///
/// **(LSP Extension)**
public struct WorkspaceTestsRequest: RequestType, Hashable {
public static let method: String = "workspace/tests"
public typealias Response = [TestItem]
public init() {}
}