<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/openstack/python-swiftclient.git/tests/unit/test_multithreading.py, branch stable/queens</title>
<subtitle>opendev.org: openstack/python-swiftclient.git
</subtitle>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/'/>
<entry>
<title>Drop testtools from test-requirements.txt</title>
<updated>2016-02-12T17:57:58+00:00</updated>
<author>
<name>Tim Burke</name>
<email>tim.burke@gmail.com</email>
</author>
<published>2015-12-04T19:28:05+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=bed6bbd5efd24234825e266a50ac37d33447d340'/>
<id>bed6bbd5efd24234825e266a50ac37d33447d340</id>
<content type='text'>
My understanding is that it was mainly being used so we could have sane
testing on py26.  With py26 support being dropped, we no longer need it.

Also drop discover from test-requirements.txt, as we don't seem to
actually use it.

Change-Id: Iee04c42890596d3b483c1473169480a3ae19aac8
Related-Change: I37116731db11449d0c374a6a83a3a43789a19d5f
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
My understanding is that it was mainly being used so we could have sane
testing on py26.  With py26 support being dropped, we no longer need it.

Also drop discover from test-requirements.txt, as we don't seem to
actually use it.

Change-Id: Iee04c42890596d3b483c1473169480a3ae19aac8
Related-Change: I37116731db11449d0c374a6a83a3a43789a19d5f
</pre>
</div>
</content>
</entry>
<entry>
<title>Miscellaneous (mostly test) cleanup</title>
<updated>2015-10-08T05:33:42+00:00</updated>
<author>
<name>Tim Burke</name>
<email>tim.burke@gmail.com</email>
</author>
<published>2015-09-10T00:41:21+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=9fed7ed5e1f6dd3e589a35e3ee4abecb676f2188'/>
<id>9fed7ed5e1f6dd3e589a35e3ee4abecb676f2188</id>
<content type='text'>
 * Always use testtools.TestCase, since we're relying on testtools
 * Always use mock (as opposed to unittest.mock) since we're relying on
   mock
 * Add note about when a missing logging handler was added
 * Stop %-formatting the giant usage string that doesn't actually need
   any formatting
 * Prefer assertIs, assertIn, assertIsInstance over assertTrue
 * Use else-self.fail instead of sentinel values
 * Check resp.get('error') is None before checking resp['success'] is
   True, so test failures actually tell you something useful
 * Tighten some isinstance assertions
 * Import MockHttpTest from correct location
 * Only populate clean_os_environ once
 * Use setUp for setup, not __init__
 * Replace assertIn(key, dict) and assertEqual(foo, dict[key]) with
   assertEqual(foo, dict.get(key)) when key is a literal and foo is not
   None
 * Use mock.patch.object instead of manually patching for tests
 * Use six.binary_type instead of type(''.encode('utf-8'))
 * Stop shadowing builtin bytes
 * Reclaim some margin
 * Stop checking the return-type of encode_utf8; we already know it's
   bytes

Change-Id: I2138ea553378ce88810b7353147c8645a8f8c90e
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
 * Always use testtools.TestCase, since we're relying on testtools
 * Always use mock (as opposed to unittest.mock) since we're relying on
   mock
 * Add note about when a missing logging handler was added
 * Stop %-formatting the giant usage string that doesn't actually need
   any formatting
 * Prefer assertIs, assertIn, assertIsInstance over assertTrue
 * Use else-self.fail instead of sentinel values
 * Check resp.get('error') is None before checking resp['success'] is
   True, so test failures actually tell you something useful
 * Tighten some isinstance assertions
 * Import MockHttpTest from correct location
 * Only populate clean_os_environ once
 * Use setUp for setup, not __init__
 * Replace assertIn(key, dict) and assertEqual(foo, dict[key]) with
   assertEqual(foo, dict.get(key)) when key is a literal and foo is not
   None
 * Use mock.patch.object instead of manually patching for tests
 * Use six.binary_type instead of type(''.encode('utf-8'))
 * Stop shadowing builtin bytes
 * Reclaim some margin
 * Stop checking the return-type of encode_utf8; we already know it's
   bytes

Change-Id: I2138ea553378ce88810b7353147c8645a8f8c90e
</pre>
</div>
</content>
</entry>
<entry>
<title>change deprecated assertEquals to assertEqual</title>
<updated>2015-08-06T09:50:33+00:00</updated>
<author>
<name>Hiroshi Miura</name>
<email>miurahr@nttdata.co.jp</email>
</author>
<published>2015-08-03T03:20:44+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=be0f1aad8a5ed6f8d61016902c713db609ad834c'/>
<id>be0f1aad8a5ed6f8d61016902c713db609ad834c</id>
<content type='text'>
fix against H234: assertEquals() logs a DeprecationWarning
in Python3.x. use assertEqual() instead.

Closes-bug: #1480776

Change-Id: Iffda6bb5f2616d4af4567eeea37bb26531e34371
Signed-off-by: Hiroshi Miura &lt;miurahr@nttdata.co.jp&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
fix against H234: assertEquals() logs a DeprecationWarning
in Python3.x. use assertEqual() instead.

Closes-bug: #1480776

Change-Id: Iffda6bb5f2616d4af4567eeea37bb26531e34371
Signed-off-by: Hiroshi Miura &lt;miurahr@nttdata.co.jp&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Properly test raw writes in Python 3</title>
<updated>2015-07-07T22:39:02+00:00</updated>
<author>
<name>Tim Burke</name>
<email>tim.burke@gmail.com</email>
</author>
<published>2015-05-18T06:51:37+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=cf0b6c03df5b014e8c21ffcb0fe92f58e11c7ae3'/>
<id>cf0b6c03df5b014e8c21ffcb0fe92f58e11c7ae3</id>
<content type='text'>
Previously we were trying to test writing bytes in Python 3 using only
native (unicode) string objects. That doesn't test what we thought we
were testing.

Change-Id: I10a0a38143d7f7d850ab9a7005ad87f5d314c375
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously we were trying to test writing bytes in Python 3 using only
native (unicode) string objects. That doesn't test what we thought we
were testing.

Change-Id: I10a0a38143d7f7d850ab9a7005ad87f5d314c375
</pre>
</div>
</content>
</entry>
<entry>
<title>Fix crash when stat'ing objects with non-ascii names</title>
<updated>2015-02-17T14:52:35+00:00</updated>
<author>
<name>Joel Wright</name>
<email>joel.wright@sohonet.com</email>
</author>
<published>2015-01-14T11:10:48+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=cac21e3cff323d828b69b2280151b9c505bdaeda'/>
<id>cac21e3cff323d828b69b2280151b9c505bdaeda</id>
<content type='text'>
This patch fixes a crash and stack trace in stat when an object
name contains non-ascii characters.

Change-Id: Ib6dc686771e593243de56cafc100b17e51d9d9d5
Closes-Bug: 1411665
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch fixes a crash and stack trace in stat when an object
name contains non-ascii characters.

Change-Id: Ib6dc686771e593243de56cafc100b17e51d9d9d5
Closes-Bug: 1411665
</pre>
</div>
</content>
</entry>
<entry>
<title>This patch fixes downloading files to stdout.</title>
<updated>2015-01-23T11:46:13+00:00</updated>
<author>
<name>Joel Wright</name>
<email>joel.wright@sohonet.com</email>
</author>
<published>2015-01-04T21:14:02+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=bd42c2b00d0e4a18d15fd494bd9b9101742c4a37'/>
<id>bd42c2b00d0e4a18d15fd494bd9b9101742c4a37</id>
<content type='text'>
This patch fixes downloading files to stdout and modifies
_SwiftReader to operate as an iterator that performs file
checks at the end of iteration as well as a context manager.
File verification checks have been removed from __exit__
and added to __iter__.

Change-Id: I3250bdeeef8484a9122c4b5b854756a7c8f8731e
Closes-Bug: 1395922
Closes-Bug: 1387376
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch fixes downloading files to stdout and modifies
_SwiftReader to operate as an iterator that performs file
checks at the end of iteration as well as a context manager.
File verification checks have been removed from __exit__
and added to __iter__.

Change-Id: I3250bdeeef8484a9122c4b5b854756a7c8f8731e
Closes-Bug: 1395922
Closes-Bug: 1387376
</pre>
</div>
</content>
</entry>
<entry>
<title>Add importable SwiftService incorporating shell.py logic</title>
<updated>2014-08-26T12:14:21+00:00</updated>
<author>
<name>Joel Wright</name>
<email>joel.wright@sohonet.com</email>
</author>
<published>2014-04-04T19:13:01+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=24673f8d19fe2f48964f528369081c37e880ec47'/>
<id>24673f8d19fe2f48964f528369081c37e880ec47</id>
<content type='text'>
This patch adds a SwiftService class that incorporates the high
level logic from swiftclient/shell.py. It also ports shell.py to
use the new class, and updates the code in swiftclient/multithreading.py
to allow the SwiftService to be used for multiple operations whilst
using only one thread pool.

Currently, code that imports swiftclient has to have its own logic for
things like creating large objects, parallel uploads, and parallel
downloads. This patch adds a SwiftService class that makes that
functionality available in Python code as well as through the shell.

Change-Id: I08c5796b4c01001d79fd571651c3017c16462ffd
Implements: blueprint bin-swift-logic-as-importable-library
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This patch adds a SwiftService class that incorporates the high
level logic from swiftclient/shell.py. It also ports shell.py to
use the new class, and updates the code in swiftclient/multithreading.py
to allow the SwiftService to be used for multiple operations whilst
using only one thread pool.

Currently, code that imports swiftclient has to have its own logic for
things like creating large objects, parallel uploads, and parallel
downloads. This patch adds a SwiftService class that makes that
functionality available in Python code as well as through the shell.

Change-Id: I08c5796b4c01001d79fd571651c3017c16462ffd
Implements: blueprint bin-swift-logic-as-importable-library
</pre>
</div>
</content>
</entry>
<entry>
<title>Remove testtools.main() call from tests</title>
<updated>2014-05-20T14:54:41+00:00</updated>
<author>
<name>Christian Schwede</name>
<email>christian.schwede@enovance.com</email>
</author>
<published>2014-05-20T14:49:49+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=876238a134d6f0332eeea57e03c3858b452895a1'/>
<id>876238a134d6f0332eeea57e03c3858b452895a1</id>
<content type='text'>
There is no testtools.main() at all (this was a
unittest.main() before). Let's remove this unused
and non-working code.

The following code can be used if someone needs
to start tests manually:

    python -m unittest &lt;test_file.py&gt;

Change-Id: Id5162ac73825584df6c23dbe68786ff3355fc6ae
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There is no testtools.main() at all (this was a
unittest.main() before). Let's remove this unused
and non-working code.

The following code can be used if someone needs
to start tests manually:

    python -m unittest &lt;test_file.py&gt;

Change-Id: Id5162ac73825584df6c23dbe68786ff3355fc6ae
</pre>
</div>
</content>
</entry>
<entry>
<title>Add functional tests for python-swiftclient</title>
<updated>2014-05-05T09:53:37+00:00</updated>
<author>
<name>Christian Schwede</name>
<email>christian.schwede@enovance.com</email>
</author>
<published>2014-02-25T21:42:17+00:00</published>
<link rel='alternate' type='text/html' href='http://91.123.203.49/cgit/delta/openstack/python-swiftclient.git/commit/?id=eb94ac076dec7e08f4e6c4c55d7c6f60b1b1cbfd'/>
<id>eb94ac076dec7e08f4e6c4c55d7c6f60b1b1cbfd</id>
<content type='text'>
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
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
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
</pre>
</div>
</content>
</entry>
</feed>
