From 27d8aa7589e61a8234ce794c972381aaa0f9b21d Mon Sep 17 00:00:00 2001
From: Holger Nahrstaedt <holger@nahrstaedt.de>
Date: Sat, 3 Mar 2018 15:35:09 +0100
Subject: [PATCH] fix unit test

---
 beem/version.py             |  3 ++-
 beemapi/version.py          |  3 ++-
 beembase/version.py         |  3 ++-
 beemgrapheneapi/version.py  |  3 ++-
 beemgraphenebase/version.py |  3 ++-
 setup.py                    | 15 ++++++++++-----
 tests/test_block.py         |  2 +-
 tox.ini                     |  6 +++---
 8 files changed, 24 insertions(+), 14 deletions(-)

diff --git a/beem/version.py b/beem/version.py
index a0716dad..beb9d422 100644
--- a/beem/version.py
+++ b/beem/version.py
@@ -1,3 +1,4 @@
 
-# THIS FILE IS GENERATED FROM beem SETUP.PY
+""" THIS FILE IS GENERATED FROM beem SETUP.PY
+"""
 version = '0.19.11'
diff --git a/beemapi/version.py b/beemapi/version.py
index a0716dad..beb9d422 100644
--- a/beemapi/version.py
+++ b/beemapi/version.py
@@ -1,3 +1,4 @@
 
-# THIS FILE IS GENERATED FROM beem SETUP.PY
+""" THIS FILE IS GENERATED FROM beem SETUP.PY
+"""
 version = '0.19.11'
diff --git a/beembase/version.py b/beembase/version.py
index a0716dad..beb9d422 100644
--- a/beembase/version.py
+++ b/beembase/version.py
@@ -1,3 +1,4 @@
 
-# THIS FILE IS GENERATED FROM beem SETUP.PY
+""" THIS FILE IS GENERATED FROM beem SETUP.PY
+"""
 version = '0.19.11'
diff --git a/beemgrapheneapi/version.py b/beemgrapheneapi/version.py
index a0716dad..beb9d422 100644
--- a/beemgrapheneapi/version.py
+++ b/beemgrapheneapi/version.py
@@ -1,3 +1,4 @@
 
-# THIS FILE IS GENERATED FROM beem SETUP.PY
+""" THIS FILE IS GENERATED FROM beem SETUP.PY
+"""
 version = '0.19.11'
diff --git a/beemgraphenebase/version.py b/beemgraphenebase/version.py
index a0716dad..beb9d422 100644
--- a/beemgraphenebase/version.py
+++ b/beemgraphenebase/version.py
@@ -1,3 +1,4 @@
 
-# THIS FILE IS GENERATED FROM beem SETUP.PY
+""" THIS FILE IS GENERATED FROM beem SETUP.PY
+"""
 version = '0.19.11'
diff --git a/setup.py b/setup.py
index 894b7cfb..244d78b4 100755
--- a/setup.py
+++ b/setup.py
@@ -1,13 +1,15 @@
-#!/usr/bin/env python3
-
+# -*- coding: utf-8 -*-
+"""Packaging logic for beem."""
+import codecs
+import io
 import os
 import sys
-import io
+
 from setuptools import setup
 
 # Work around mbcs bug in distutils.
 # http://bugs.python.org/issue10945
-import codecs
+
 try:
     codecs.lookup('mbcs')
 except LookupError:
@@ -34,8 +36,11 @@ requires = [
 
 
 def write_version_py(filename):
+    """ Write version
+    """
     cnt = """
-# THIS FILE IS GENERATED FROM beem SETUP.PY
+\""" THIS FILE IS GENERATED FROM beem SETUP.PY
+\"""
 version = '%(version)s'
 """
     with open(filename, 'w') as a:
diff --git a/tests/test_block.py b/tests/test_block.py
index 19aa9f3e..7fe7a8c6 100644
--- a/tests/test_block.py
+++ b/tests/test_block.py
@@ -43,5 +43,5 @@ class Testcases(unittest.TestCase):
     def test_block_ops(self):
         bts = self.bts
         block = Block(20000000, steem_instance=bts)
-        self.assertTrue(len(block.ops))
+        self.assertTrue(len(block.ops()))
         self.assertTrue(isinstance(block.ops_statistics(), dict))
diff --git a/tox.ini b/tox.ini
index 7ce302ad..3bd1aafc 100644
--- a/tox.ini
+++ b/tox.ini
@@ -22,7 +22,7 @@ deps=
     pep8-naming
     flake8-colors
 commands=
-    flake8 beem beemapi beembase beemgraphenebase beemgrapheneapi tests
+    flake8 beem beemapi beembase beemgraphenebase beemgrapheneapi setup.py
 
 [testenv:pylint]
 deps=
@@ -99,7 +99,7 @@ commands =
 # defaults to selecting all other errors so we do not need select=E,F,W,I,D
 # Once Flake8 3.0 is released and in a good state, we can use both and it will
 # work well \o/
-ignore = D203
+ignore = D203,E129,E501,F401,E722,E122,E111,E114,D102,D100,D103,D107
 exclude =
     .tox,
     .git,
@@ -115,4 +115,4 @@ exclude =
 max-complexity = 10
 import-order-style = google
 application-import-names = flake8
-format = ${cyan}%(path)s${reset}:${yellow_bold}%(row)d${reset}:${green_bold}%(col)d${reset}: ${red_bold}%(code)s${reset} %(text)s
+# format = ${cyan}%(path)s${reset}:${yellow_bold}%(row)d${reset}:${green_bold}%(col)d${reset}: ${red_bold}%(code)s${reset} %(text)s
-- 
GitLab