Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

just disable cov-report term-missing #239

Open
wants to merge 28 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,18 +61,18 @@ jobs:
# Run tests and collect coverage data.
python -m pytest
# Generate LCOV format coverage data for coveralls.
#coverage lcov -o coverage.lcov
coverage lcov -o coverage.lcov

- name: Build packages
run: |
python -m flit build

#- name: Send coverage data to coveralls.io
# uses: coverallsapp/github-action@main
# with:
# flag-name: run-${{ join(matrix.*, '-') }}
# file: coverage.lcov
# parallel: true
- name: Send coverage data to coveralls.io
uses: coverallsapp/github-action@main
with:
flag-name: run-${{ join(matrix.*, '-') }}
file: coverage.lcov
parallel: true

finalize:
name: finalize
Expand Down
11 changes: 7 additions & 4 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,11 @@ Issues = "https://github.com/atlanticwave-sdx/pce/issues"

[project.optional-dependencies]
test = [
"pytest >= 7.1.2",
"pytest-cov >= 3.0.0",
"pytest-sugar >= 1.0.0",
"pytest == 8.0.1",
"pluggy == 1.4.0",
"coverage == 7.4.2",
"pytest-cov == 4.1.0",
"pytest-sugar == 1.0.0",
]
pygraphviz = [
"pygraphviz"
Expand All @@ -55,7 +57,7 @@ lint = [
where = "src"

[tool.pytest.ini_options]
addopts = "--cov=sdx_pce --cov-report html --cov-report term-missing"
addopts = "--cov=sdx_pce --cov-report html --cov-report lcov --cov-report term-missing:skip-covered"
testpaths = [
"tests"
]
Expand Down Expand Up @@ -84,6 +86,7 @@ omit = ["tests/*", "src/*"]
relative_files = true

[tool.coverage.report]
precision = 2
exclude_also = [
"def __repr__",
"if self.debug:",
Expand Down
1 change: 1 addition & 0 deletions src/sdx_pce/topology/grenmlconverter.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ def read_topology(self):

def add_nodes(self, nodes):
for node in nodes:
print(node)
location = node.location
logging.info(f"adding node: {node.id}")
self.grenml_manager.add_node(
Expand Down
3 changes: 0 additions & 3 deletions tests/test_te_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@ def setUp(self):
topology = json.loads(TestData.TOPOLOGY_FILE_AMLIGHT.read_text())
self.temanager = TEManager(topology)

def tearDown(self):
self.temanager = None

def test_expand_label_range(self):
"""
Test the _expand_label_range() method.
Expand Down
18 changes: 0 additions & 18 deletions tests/test_topology_grenmlconverter.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,6 @@ class GrenmlConverterTests(unittest.TestCase):
# TEST_DATA_DIR = pathlib.Path(__file__).parent / "data"
# AMLIGHT_TOPOLOGY_FILE = TEST_DATA_DIR / "topologies" / "amlight.json"

def setUp(self):
pass

def tearDown(self):
pass

def test_grenml_converter_amlight(self):
TopologyManager()

Expand All @@ -41,15 +35,3 @@ def test_grenml_converter_amlight(self):
xml = converter.get_xml_str()
print(f"XML: {xml}")
self.assertIsNotNone(xml)

def test_grenml_converter_bad_input(self):
# Ensure that GrenmlConverter fails when no topology input is
# given.
with self.assertRaises(AttributeError):
GrenmlConverter(None)

with self.assertRaises(AttributeError):
GrenmlConverter("")

with self.assertRaises(AttributeError):
GrenmlConverter("{'dummy':'dummy'}")
3 changes: 0 additions & 3 deletions tests/test_topology_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,6 @@ class TopologyManagerTests(unittest.TestCase):
def setUp(self):
self.topology_manager = TopologyManager()

def tearDown(self):
self.topology_manager = None

def test_merge_topology(self):
print("Test Topology Merge!")

Expand Down