Commit Graph

5 Commits

Author SHA1 Message Date
Tim Burke 1eda8f9f3e Rename "tests" directory to be "test" like in the swift repo
In addition to being less confusing for devs, this lets us actually run
tempauth tests in swiftclient dsvm jobs.

The job definition (over in the swift repo) specifies test/sample.conf,
which does not exist in this repo. As a result, those tests would skip
with

    SKIPPING FUNCTIONAL TESTS DUE TO NO CONFIG

Change-Id: I558dbf9a657d442e6e19468e543bbec855129eeb
2019-11-06 03:48:02 +00:00
Christian Schwede eb94ac076d Add functional tests for python-swiftclient
Coverage for swiftclient.client is 71% with these tests.

Unit tests have been moved into another subdirectory
to separate them from functional tests.

Change-Id: Ib8c4d78f7169cee893f82906f6388a5b06c45602
2014-05-05 11:53:37 +02:00
Darrell Bishop 9198e95468 Move multi-threading code to a library.
This patch extracts the multi-threading code from bin/swift into
swiftclient/multithreading and adds tests.  In particular, this new way
of doing it (with context managers) will prevent non-daemonic threads
from wedging the process when unexpected exceptions happen.

I enabled reporting of which lines, specifically, are not covered by
unit tests (added -m option to "coverage report" in .unittests).

This patch includes a drive-by fix for uploading a segmented file with
--use-slo when that object already exists.  A key of "name" was used
instead of "path", raising KeyError.

There's also another drive-by fix for uploading segmented objects with
--use-slo.  Commit 874e0e4427 regressed
this by removing the capturing of thread-worker results in
QueueFunctionThread.run().  This patch restores that functionality and
the feature (uploading SLO objects).

Change-Id: I0b4f677e4a734e83d1a25088d9a74f7d46384e53
2013-07-28 22:08:17 -07:00
Monty Taylor bfeffb6366 Use testr instead of nose.
nose is invasive and can sometimes alter the outcome of a test run. testr,
on the other hand, keeps a distinction between running tests and displaying
results of the test runs. Additionally, it supports the stock python unittest
protocol.

Even better, testr supports parallel test running, which makes things faster,
and a command "testr run --failing" which will just re-run the latest failing
tests (often something one wants to do in iterative dev)

Part of blueprint grizzly-testtools

Change-Id: I0b3f1bcb5d4ff59c65eb3219b30a9e64f54d70bd
2013-01-18 16:13:27 -05:00
Chmouel Boudjnah cb07a50900 Import script from swift to run unittests. 2012-05-08 15:18:01 +01:00