Skip to content

Build tags in test/integration break editors go language server #21269

@nirs

Description

@nirs

Some tests like mount_start_test.go use build tags:

//go:build integration

This breaks editor language server (e.g. Zed, Cursor, vscode) since they think the file is not compiled. Maybe it is possible to configure the --tags for the language server but it does not make sense to make it hard to work with.

Need to find another way to filter integration and functional tests for go test ./... without breaking editors.

Alternative: document how to configure build flags for various editors.

For Zed, editor global or project settings.json (.zed/settings.json):

{
  "lsp": {
    "gopls": {
      "initialization_options": {
        "buildFlags": ["-tags=integration,functional,iso"]
      }
    }
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions