Skip to content

Commit f48fd74

Browse files
frenzymadnesshroncok
authored andcommitted
Travis CI: Skip coalesce test for ethernet device
1 parent 4bf088f commit f48fd74

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

tests/test_scripts.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import unittest
22
import ethtool
33
import sys
4+
import os
45
from io import TextIOWrapper, BytesIO
56
from imp import load_source
67

@@ -98,6 +99,9 @@ def test_show_ring_eth(self):
9899
for expected_start, line in zip(expected_lines_start, lines):
99100
self.assertTrue(line.startswith(expected_start))
100101

102+
@unittest.skipIf('TRAVIS' in os.environ and os.environ['TRAVIS'] == 'true',
103+
'Skipping this test on Travis CI because show '
104+
'coalesce is not supported on ethernet device in VM.')
101105
def test_show_coalesce_eth(self):
102106
self.assertIsNone(peth.show_coalesce(device))
103107
expected_lines_start = ['Coalesce parameters for',

tox.ini

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,7 @@ envlist = py27,py35,py36
44
commands=
55
python tests/parse_ifconfig.py -v
66
python -m unittest discover -v
7+
passenv=
8+
TRAVIS
79
# Run all the above commands, don't worry it reports failure anyway
810
ignore_errors = True

0 commit comments

Comments
 (0)