From d5f6826a43deed7ff2ae82e3a2c4a8d51c5da67e Mon Sep 17 00:00:00 2001
From: florian <f.spreckelsen@inidscale.com>
Date: Fri, 10 Jul 2020 15:30:08 +0200
Subject: [PATCH] STY: autopep'd

---
 src/caosdb/exceptions.py         | 4 ++--
 unittests/test_error_handling.py | 8 ++++----
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/caosdb/exceptions.py b/src/caosdb/exceptions.py
index 4ff840a6..3b3d2ce4 100644
--- a/src/caosdb/exceptions.py
+++ b/src/caosdb/exceptions.py
@@ -135,7 +135,7 @@ class ResourceNotFoundException(CaosDBException):
         CaosDBException.__init__(self, msg=msg)
 
 
-######################### Transaction errors #########################
+# ######################### Transaction errors #########################
 
 
 class TransactionError(CaosDBException):
@@ -246,7 +246,7 @@ class TransactionError(CaosDBException):
 
     def get_container(self):
         """Return the Container object that contained the problematic
-        entities.  
+        entities.
 
         Returns
         -------
diff --git a/unittests/test_error_handling.py b/unittests/test_error_handling.py
index 2b079a02..d677bba5 100644
--- a/unittests/test_error_handling.py
+++ b/unittests/test_error_handling.py
@@ -242,13 +242,13 @@ def test_parent_and_properties_errors():
         if err.get_code() == parent_code:
             found_parent = True
             assert err.errors[0].entity.name == parent.name
-            assert not prop1.name in [x.name for x in
+            assert prop1.name not in [x.name for x in
                                       err.all_entities]
-            assert not prop2.name in [x.name for x in
+            assert prop2.name not in [x.name for x in
                                       err.all_entities]
         elif err.get_code() == prop_code:
             found_prop = True
-            assert not parent.name in [x.name for x in
+            assert parent.name not in [x.name for x in
                                        err.all_entities]
             for sub_err in err.errors:
                 if sub_err.get_code() == entity_code:
@@ -303,7 +303,7 @@ def test_container_with_faulty_elements():
     assert te.get_code() == container_code
     # no healthy entity caused an error
     for good in [good_rec, good_prop]:
-        assert not good in te.all_entities
+        assert good not in te.all_entities
     # all records that caused problems
     assert {rec_name, rec_auth, rec_par_prop}.issubset(te.all_entities)
     # the container error contains the errors caused by the records
-- 
GitLab