• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

pantsbuild / pants / 18913303678

29 Oct 2025 03:29PM UTC coverage: 80.004% (-0.3%) from 80.283%
18913303678

push

github

web-flow
Updating 3rd party lockfiles for PBS script and MyPy (#22796)

Also small bumps to fastapi and starlette, which updated over the last few days. Starlette updated for features, and then a security vulnerability.

Fastapi bumped just for starlette.

88 of 93 new or added lines in 73 files covered. (94.62%)

221 existing lines in 15 files now uncovered.

77334 of 96663 relevant lines covered (80.0%)

5.2 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

85.0
/src/python/pants/backend/helm/subsystems/unittest_test.py
1
# Copyright 2022 Pants project contributors (see CONTRIBUTORS.md).
2
# Licensed under the Apache License, Version 2.0 (see LICENSE).
3

4
from __future__ import annotations
1✔
5

6
import re
1✔
7

8
import pytest
1✔
9

10
from pants.backend.helm.subsystems import unittest as unittest_subsystem
1✔
11
from pants.backend.helm.subsystems.unittest import HelmUnitTestSubsystem
1✔
12
from pants.backend.helm.util_rules import tool
1✔
13
from pants.backend.helm.util_rules.tool import HelmProcess
1✔
14
from pants.engine.fs import EMPTY_DIGEST
1✔
15
from pants.engine.process import ProcessResult
1✔
16
from pants.engine.rules import QueryRule
1✔
17
from pants.testutil.rule_runner import RuleRunner
1✔
18

19

20
@pytest.fixture
1✔
21
def rule_runner() -> RuleRunner:
1✔
22
    return RuleRunner(
1✔
23
        rules=[
24
            *tool.rules(),
25
            *unittest_subsystem.rules(),
26
            QueryRule(ProcessResult, (HelmProcess,)),
27
        ]
28
    )
29

30

31
def test_install_plugin(rule_runner: RuleRunner) -> None:
1✔
32
    plugin_ls_process = HelmProcess(
1✔
33
        argv=["plugin", "ls"],
34
        input_digest=EMPTY_DIGEST,
35
        description="Verify installation of Helm plugins",
36
    )
37

38
    process_result = rule_runner.request(ProcessResult, [plugin_ls_process])
1✔
39

40
    # The result of the `helm plugin ls` command is a table with a header like
41
    #    NAME           VERSION DESCRIPTION
42
    #    plugin_name    0.1.0   Some plugin description
43
    #
44
    # So to build the test expectation we parse that output keeping
45
    # the plugin's name and version to be used in the comparison
UNCOV
46
    plugin_table_rows = process_result.stdout.decode().splitlines()[1:]
×
UNCOV
47
    loaded_plugins = [
×
48
        (columns[0].strip(), columns[1].strip())
49
        for columns in (re.split(r"\t+", line.rstrip()) for line in plugin_table_rows)
50
    ]
51

UNCOV
52
    assert loaded_plugins == [
×
53
        (HelmUnitTestSubsystem.plugin_name, HelmUnitTestSubsystem.default_version)
54
    ]
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc