Skip to content

Unit test coverage gap when running 3.14 #2446

@parthea

Description

@parthea

I'm hitting a strange issue where there is a coverage gap in python 3.14 in unit tests, but in all other python runtimes there is no gap. See https://github.com/googleapis/gapic-generator-python/actions/runs/18045136023/job/51353943485?pr=2344

ERROR: Coverage failure: total of 99 is less than fail-under=100


================================ tests coverage ================================
_____________ coverage: platform linux, python 3.14.0-candidate-3 ______________

Name                                                    Stmts   Miss Branch BrPart  Cover   Missing
---------------------------------------------------------------------------------------------------
gapic/configurable_snippetgen/__init__.py                   0      0      0      0   100%
gapic/configurable_snippetgen/configured_snippet.py       103      0     18      0   100%
gapic/configurable_snippetgen/libcst_utils.py              27      0      6      0   100%
gapic/generator/__init__.py                                 2      0      0      0   100%
gapic/generator/formatter.py                                6      0      0      0   100%
gapic/generator/generator.py                              131      0     48      0   100%
gapic/samplegen/__init__.py                                 3      0      0      0   100%
gapic/samplegen/manifest.py                                20      0      2      0   100%
gapic/samplegen/samplegen.py                              383      0    158      0   100%
gapic/samplegen_utils/__init__.py                           4      0      0      0   100%
gapic/samplegen_utils/snippet_index.py                     80      0     24      0   100%
gapic/samplegen_utils/types.py                             64      0      8      0   100%
gapic/samplegen_utils/utils.py                             28      0      8      0   100%
gapic/samplegen_utils/yaml.py                              38      0      0      0   100%
gapic/schema/__init__.py                                    4      0      0      0   100%
gapic/schema/api.py                                       471      0    160      1    99%   938->943
gapic/schema/imp.py                                        16      0      6      0   100%
gapic/schema/metadata.py                                  129      0     46      0   100%
gapic/schema/mixins.py                                      2      0      0      0   100%
gapic/schema/naming.py                                     76      0     20      0   100%
gapic/schema/wrappers.py                                  867      0    246      0   100%
gapic/templates/_license.j2                                 0      0      0      0   100%
gapic/templates/examples/_generated_sample_comment.j2       0      0      0      0   100%
gapic/utils/__init__.py                                    19      0      0      0   100%
gapic/utils/cache.py                                       10      0      4      0   100%
gapic/utils/case.py                                        10      0      0      0   100%
gapic/utils/checks.py                                       5      0      0      0   100%
gapic/utils/code.py                                        14      0      2      0   100%
gapic/utils/doc.py                                          3      0      0      0   100%
gapic/utils/filename.py                                     5      0      0      0   100%
gapic/utils/lines.py                                       58      0     30      0   100%
gapic/utils/options.py                                     76      0     22      0   100%
gapic/utils/reserved_names.py                               1      0      0      0   100%
gapic/utils/rst.py                                         13      0      6      0   100%
gapic/utils/uri_conv.py                                    19      0      4      0   100%
gapic/utils/uri_sample.py                                  30      0      6      0   100%
---------------------------------------------------------------------------------------------------
TOTAL                                                    2717      0    824      1    99%
FAIL Required test coverage of 100% not reached. Total coverage: 99.97%
============================= 625 passed in 6.63s ==============================
nox > Command py.test -vv -n=auto --cov=gapic --cov-config=.coveragerc --cov-report=term --cov-fail-under=100 tests/unit failed with exit code 1
nox > Session unit-3.14 failed.

Metadata

Metadata

Assignees

Labels

priority: p2Moderately-important priority. Fix may not be included in next release.type: processA process-related concern. May include testing, release, or the like.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions