summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Engestrom <eric@engestrom.ch>2016-04-03 19:21:32 +0100
committerVinson Lee <vlee@freedesktop.org>2016-04-16 22:40:00 -0700
commit0927771e51a8c7883e1e9b20923fcb2254e3fe36 (patch)
treee18e7579d7fe396119571954a8a65826c3cad29b
parente24a5e9e3d6ba7aeac1cdf7e2bc542edeb827581 (diff)
unittests: Fix spelling mistakes
Signed-off-by: Eric Engestrom <eric@engestrom.ch> Reviewed-by: Dylan Baker <baker.dylan.c@gmail.com> Signed-off-by: Vinson Lee <vlee@freedesktop.org>
-rw-r--r--unittests/backends_tests.py2
-rw-r--r--unittests/base_tests.py10
-rw-r--r--unittests/core_tests.py2
-rw-r--r--unittests/dmesg_tests.py2
-rw-r--r--unittests/glsl_parser_test_tests.py2
-rw-r--r--unittests/json_backend_tests.py4
-rw-r--r--unittests/json_results_update_tests.py2
-rw-r--r--unittests/log_tests.py2
-rw-r--r--unittests/options_tests.py2
-rw-r--r--unittests/profile_tests.py6
-rw-r--r--unittests/results_tests.py2
-rw-r--r--unittests/run_parser_tests.py16
-rw-r--r--unittests/status_tests.py2
-rw-r--r--unittests/utils.py2
14 files changed, 28 insertions, 28 deletions
diff --git a/unittests/backends_tests.py b/unittests/backends_tests.py
index c3cda86c2..81466ecc5 100644
--- a/unittests/backends_tests.py
+++ b/unittests/backends_tests.py
@@ -88,7 +88,7 @@ def test_get_backend():
@nt.raises(backends.BackendError)
def test_get_backend_unknown():
- """backends.get_backend: An error is raised with an unkown backend."""
+ """backends.get_backend: An error is raised with an unknown backend."""
backends.get_backend('obviously fake backend')
diff --git a/unittests/base_tests.py b/unittests/base_tests.py
index 2e646622a..eea830ba8 100644
--- a/unittests/base_tests.py
+++ b/unittests/base_tests.py
@@ -59,7 +59,7 @@ from framework import log, dmesg
class TestTest(Test):
""" A class for testing that implements a dummy interpret_result
- interpret_result() can ve overwritten by setting the
+ interpret_result() can be overwritten by setting the
self.test_interpret_result name
"""
@@ -118,8 +118,8 @@ def test_timeout_kill_children():
def __call__(self, *args, **kwargs):
self.popen = subprocess.Popen(*args, **kwargs)
- # if commuincate cis called successfully then the proc will be
- # reset to None, whic will make the test fail.
+ # if communicate is called successfully then the proc will be
+ # reset to None, which will make the test fail.
self.popen.communicate = mock.Mock(return_value=('out', 'err'))
return self.popen
@@ -159,7 +159,7 @@ def test_timeout_kill_children():
test.run()
# Check to see if the Popen has children, even after it should have
- # recieved a TimeoutExpired.
+ # received a TimeoutExpired.
proc = psutil.Process(os.getsid(proxy.popen.pid))
children = proc.children(recursive=True)
@@ -423,7 +423,7 @@ class TestExecuteTraceback(object):
It's fragile to record the actual traceback, and it's unlikely
that it can easily be implemented differently than the way the original
- code is implimented, so this doesn't do that, it just verifies there is
+ code is implemented, so this doesn't do that, it just verifies there is
a value.
"""
diff --git a/unittests/core_tests.py b/unittests/core_tests.py
index df7f48b19..a28ebfb5d 100644
--- a/unittests/core_tests.py
+++ b/unittests/core_tests.py
@@ -109,7 +109,7 @@ def test_PiglitConfig_init():
def test_parse_listfile_return():
"""core.parse_listfile(): returns a list-like object
- Given a file with a newline seperated list of results, parse_listfile
+ Given a file with a newline separated list of results, parse_listfile
should return a list of files with no whitespace
"""
diff --git a/unittests/dmesg_tests.py b/unittests/dmesg_tests.py
index 47c19591d..b2f537c87 100644
--- a/unittests/dmesg_tests.py
+++ b/unittests/dmesg_tests.py
@@ -151,7 +151,7 @@ class TestBaseDmesg(object):
def test_update_result_regex_no_match():
- """dmesg.BaseDmesg.update_result: if no regex matches dont change status"""
+ """dmesg.BaseDmesg.update_result: if no regex matches don't change status"""
dmesg_ = TestDmesg()
dmesg_.regex = re.compile(r'nomatchforthisreally')
result = results.TestResult('pass')
diff --git a/unittests/glsl_parser_test_tests.py b/unittests/glsl_parser_test_tests.py
index 048c5a426..7fb990216 100644
--- a/unittests/glsl_parser_test_tests.py
+++ b/unittests/glsl_parser_test_tests.py
@@ -303,7 +303,7 @@ def glslparser_exetensions_seperators():
""" GlslParserTest() can only have [A-Za-z_] as characters
This test generates a number of tests that should catch the majority of
- errors relating to seperating extensions in the config block of a
+ errors relating to separating extensions in the config block of a
glslparser test
"""
diff --git a/unittests/json_backend_tests.py b/unittests/json_backend_tests.py
index eb76bfb46..7d76b7482 100644
--- a/unittests/json_backend_tests.py
+++ b/unittests/json_backend_tests.py
@@ -156,12 +156,12 @@ def test_update_results_old():
"""backends.json.update_results(): updates results
Because of the design of the our updates (namely that they silently
- incrementally update from x to y) it's impossible to konw exactly what
+ incrementally update from x to y) it's impossible to know exactly what
we'll get at th end without having tests that have to be reworked each time
updates are run. Since there already is (at least for v0 -> v1) a fairly
comprehensive set of tests, this test only tests that update_results() has
been set equal to the CURRENT_JSON_VERSION, (which is one of the effects of
- runing update_results() with the assumption that there is sufficient other
+ running update_results() with the assumption that there is sufficient other
testing of the update process.
"""
diff --git a/unittests/json_results_update_tests.py b/unittests/json_results_update_tests.py
index e0d2d6a95..5f4fc00b6 100644
--- a/unittests/json_results_update_tests.py
+++ b/unittests/json_results_update_tests.py
@@ -200,7 +200,7 @@ class TestV0toV1(object):
def test_dont_break_single_subtest(self):
"""backends.json.update_results (0 -> 1): Don't break single subtest entries
- A test with a single subtest was written correctly before, dont break it by
+ A test with a single subtest was written correctly before, don't break it by
removing the name of the test. ex:
test/foo/bar: {
...
diff --git a/unittests/log_tests.py b/unittests/log_tests.py
index 8a90a21d5..d8d57667a 100644
--- a/unittests/log_tests.py
+++ b/unittests/log_tests.py
@@ -38,7 +38,7 @@ TEST_STATE = {'total': 0, 'complete': 0, 'lastlength': 0, 'running': [],
@utils.nose_generator
def test_initialize():
- """ Generate tests for class initializiation """
+ """ Generate tests for class initialization """
check_initialize = lambda c, *a: c(*a)
for name, class_ in [('QuiteLog', log.QuietLog),
diff --git a/unittests/options_tests.py b/unittests/options_tests.py
index 8ba13fbaa..8f5f7c16d 100644
--- a/unittests/options_tests.py
+++ b/unittests/options_tests.py
@@ -136,7 +136,7 @@ class TestReListDescriptor(object):
create=True)
@nt.raises(AttributeError)
def test_get_not_exists_fail(self):
- """options._ReListDescriptor.__get__: Raises AttributError if name doesn't exist and cant be created"""
+ """options._ReListDescriptor.__get__: Raises AttributError if name doesn't exist and can't be created"""
self.test.notexists # pylint: disable=pointless-statement
def test_set_relist(self):
diff --git a/unittests/profile_tests.py b/unittests/profile_tests.py
index 6abbae56d..48e9d969e 100644
--- a/unittests/profile_tests.py
+++ b/unittests/profile_tests.py
@@ -51,7 +51,7 @@ def test_initialize_testprofile():
def test_load_test_profile_no_profile():
"""profile.load_test_profile: Loading a module with no profile name exits
- Beacuse load_test_profile uses test.{} to load a module we need a module in
+ Because load_test_profile uses test.{} to load a module we need a module in
tests that doesn't have a profile attribute. The only module that currently
meets that requirement is __init__.py
@@ -78,7 +78,7 @@ def test_testprofile_default_dmesg():
def test_testprofile_set_dmesg_true():
- """profile.TestProfile: Dmesg returns an apropriate dmesg is ste to True"""
+ """profile.TestProfile: Dmesg returns an appropriate dmesg is set to True"""
utils.platform_check('linux')
profile_ = profile.TestProfile()
profile_.dmesg = True
@@ -345,7 +345,7 @@ def test_testprofile_allow_reassignment_with_groupmanager():
def test_testprofile_allow_reassignemnt_stacked():
"""profile.profile.TestDict.allow_reassignment: check stacking cornercase
- There is an odd corner case in the original (obvious) implmentation of this
+ There is an odd corner case in the original (obvious) implementation of this
function, If one opens two context managers and then returns from the inner
one assignment will not be allowed, even though one is still inside the
first context manager.
diff --git a/unittests/results_tests.py b/unittests/results_tests.py
index a10978501..7cdb849ff 100644
--- a/unittests/results_tests.py
+++ b/unittests/results_tests.py
@@ -110,7 +110,7 @@ def test_TestResult_from_dict_inst():
class TestTestResultFromDictAttributes(object):
- """A series of tests to show that each attribute is sucessfully populated.
+ """A series of tests to show that each attribute is successfully populated.
"""
@classmethod
def setup_class(cls):
diff --git a/unittests/run_parser_tests.py b/unittests/run_parser_tests.py
index 44a123548..7bb76763c 100644
--- a/unittests/run_parser_tests.py
+++ b/unittests/run_parser_tests.py
@@ -45,7 +45,7 @@ class TestWithEnvClean(object):
method.
Using this gives us the assurance that we're not relying on settings from
- other tests, making ours pass or fail, and that os.enviorn is the same
+ other tests, making ours pass or fail, and that os.environ is the same
going in as it is going out.
This is modeled after Go's defer keyword.
@@ -62,14 +62,14 @@ class TestWithEnvClean(object):
del os.environ[var]
def defer(self, func, *args):
- """ Add a function (with arguments) to be run durring cleanup """
+ """ Add a function (with arguments) to be run during cleanup """
self._teardown_calls.append((func, args))
def teardown(self):
""" Teardown the test
- Restore any variables that were unset at the begining of the test, and
- run any differed methods.
+ Restore any variables that were unset at the beginning of the test, and
+ run any deferred methods.
"""
for key, value, restore in self._saved:
@@ -79,7 +79,7 @@ class TestWithEnvClean(object):
elif restore:
os.environ[key] = value
- # Teardown calls is a FIFO stack, the defered calls must be run in
+ # Teardown calls is a FIFO stack, the deferred calls must be run in
# reversed order to make any sense
for call, args in reversed(self._teardown_calls):
call(*args)
@@ -88,7 +88,7 @@ class TestWithEnvClean(object):
class _Helpers(TestWithEnvClean):
""" Some helpers to be shared between tests """
def _unset_config(self):
- """ Ensure that no config files are being accidently loaded """
+ """ Ensure that no config files are being accidentally loaded """
self.add_teardown('HOME')
self.add_teardown('XDG_CONFIG_HOME')
@@ -158,7 +158,7 @@ class TestBackend(_Helpers):
self._unset_config()
self._move_piglit_conf()
- # This has sideffects, it shouldn't effect anything in this module, but
+ # This has side effects, it shouldn't effect anything in this module, but
# it may cause later problems. But without this we get ugly error spew
# from this test.
sys.stderr = open(os.devnull, 'w')
@@ -251,7 +251,7 @@ class TestPlatform(_Helpers):
self._unset_config()
self._move_piglit_conf()
- # This has sideffects, it shouldn't effect anything in this module, but
+ # This has side effects, it shouldn't effect anything in this module, but
# it may cause later problems. But without this we get ugly error spew
# from this test.
sys.stderr = open(os.devnull, 'w')
diff --git a/unittests/status_tests.py b/unittests/status_tests.py
index 00f00e8e5..e4318042b 100644
--- a/unittests/status_tests.py
+++ b/unittests/status_tests.py
@@ -146,7 +146,7 @@ def test_not_change():
This checks that new < old and old < new do not return true. This is meant
for checking skip and notrun, which we don't want to show up as regressions
- and fixes, but to go in their own special catagories.
+ and fixes, but to go in their own special categories.
"""
nt.assert_false(new < old,
diff --git a/unittests/utils.py b/unittests/utils.py
index 3bfafcdc8..255f253bc 100644
--- a/unittests/utils.py
+++ b/unittests/utils.py
@@ -319,7 +319,7 @@ def nose_generator(func):
def binary_check(bin_, errno_=None):
- """Check for the existance of a binary or raise SkipTest.
+ """Check for the existence of a binary or raise SkipTest.
If an errno_ is provided then a skip test will be raised unless the error
number provided is raised, or no error is raised.