diff options
author | Ismaël Bouya <ismael.bouya@normalesup.org> | 2018-04-20 20:09:13 +0200 |
---|---|---|
committer | Ismaël Bouya <ismael.bouya@normalesup.org> | 2018-04-20 20:16:18 +0200 |
commit | 3080f31d1ee74104640dcff451922cd0ae88ee22 (patch) | |
tree | 81570ba2eb909b05e7aa4805f5535e47e1df6a11 /tests/test_store.py | |
parent | 9fe90554ff1c8c7aea9e1e1e210419a845579edd (diff) | |
download | Trader-3080f31d1ee74104640dcff451922cd0ae88ee22.tar.gz Trader-3080f31d1ee74104640dcff451922cd0ae88ee22.tar.zst Trader-3080f31d1ee74104640dcff451922cd0ae88ee22.zip |
Move acceptance tests to common directory
Diffstat (limited to 'tests/test_store.py')
-rw-r--r-- | tests/test_store.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/test_store.py b/tests/test_store.py index e281adb..ffd2645 100644 --- a/tests/test_store.py +++ b/tests/test_store.py | |||
@@ -4,12 +4,14 @@ import datetime | |||
4 | import threading | 4 | import threading |
5 | import market, portfolio, store | 5 | import market, portfolio, store |
6 | 6 | ||
7 | @unittest.skipUnless("unit" in limits, "Unit skipped") | ||
7 | class NoopLockTest(unittest.TestCase): | 8 | class NoopLockTest(unittest.TestCase): |
8 | def test_with(self): | 9 | def test_with(self): |
9 | noop_lock = store.NoopLock() | 10 | noop_lock = store.NoopLock() |
10 | with noop_lock: | 11 | with noop_lock: |
11 | self.assertTrue(True) | 12 | self.assertTrue(True) |
12 | 13 | ||
14 | @unittest.skipUnless("unit" in limits, "Unit skipped") | ||
13 | class LockedVarTest(unittest.TestCase): | 15 | class LockedVarTest(unittest.TestCase): |
14 | 16 | ||
15 | def test_values(self): | 17 | def test_values(self): |
@@ -61,6 +63,7 @@ class LockedVarTest(unittest.TestCase): | |||
61 | thread3.join() | 63 | thread3.join() |
62 | self.assertEqual("Bar", locked_var.get()[0:3]) | 64 | self.assertEqual("Bar", locked_var.get()[0:3]) |
63 | 65 | ||
66 | @unittest.skipUnless("unit" in limits, "Unit skipped") | ||
64 | class TradeStoreTest(WebMockTestCase): | 67 | class TradeStoreTest(WebMockTestCase): |
65 | def test_compute_trades(self): | 68 | def test_compute_trades(self): |
66 | self.m.balances.currencies.return_value = ["XMR", "DASH", "XVG", "BTC", "ETH"] | 69 | self.m.balances.currencies.return_value = ["XMR", "DASH", "XVG", "BTC", "ETH"] |
@@ -285,6 +288,7 @@ class TradeStoreTest(WebMockTestCase): | |||
285 | 288 | ||
286 | self.assertEqual([trade_mock1, trade_mock2], trade_store.pending) | 289 | self.assertEqual([trade_mock1, trade_mock2], trade_store.pending) |
287 | 290 | ||
291 | @unittest.skipUnless("unit" in limits, "Unit skipped") | ||
288 | class BalanceStoreTest(WebMockTestCase): | 292 | class BalanceStoreTest(WebMockTestCase): |
289 | def setUp(self): | 293 | def setUp(self): |
290 | super().setUp() | 294 | super().setUp() |
@@ -437,6 +441,7 @@ class BalanceStoreTest(WebMockTestCase): | |||
437 | self.assertEqual(1, as_json["BTC"]) | 441 | self.assertEqual(1, as_json["BTC"]) |
438 | self.assertEqual(2, as_json["ETH"]) | 442 | self.assertEqual(2, as_json["ETH"]) |
439 | 443 | ||
444 | @unittest.skipUnless("unit" in limits, "Unit skipped") | ||
440 | class ReportStoreTest(WebMockTestCase): | 445 | class ReportStoreTest(WebMockTestCase): |
441 | def test_add_log(self): | 446 | def test_add_log(self): |
442 | with self.subTest(market=self.m): | 447 | with self.subTest(market=self.m): |
@@ -997,6 +1002,7 @@ class ReportStoreTest(WebMockTestCase): | |||
997 | 'action': 'Hey' | 1002 | 'action': 'Hey' |
998 | }) | 1003 | }) |
999 | 1004 | ||
1005 | @unittest.skipUnless("unit" in limits, "Unit skipped") | ||
1000 | class PortfolioTest(WebMockTestCase): | 1006 | class PortfolioTest(WebMockTestCase): |
1001 | def setUp(self): | 1007 | def setUp(self): |
1002 | super().setUp() | 1008 | super().setUp() |