Browse Source

updated test imports and CI to reflect py2 compat

gwillz 3 years ago
parent
commit
044f80d8ce
6 changed files with 11 additions and 11 deletions
  1. 3 3
      .gitlab-ci.yml
  2. 2 2
      tests/abject.py
  3. 2 2
      tests/avent_impl.py
  4. 1 1
      tests/event.py
  5. 1 1
      tests/fluid.py
  6. 2 2
      tests/strict.py

+ 3 - 3
.gitlab-ci.yml

@@ -45,7 +45,7 @@ lint:py2:
  - linux
  script:
  - wget https://git.mk2es.com.au/snippets/8/raw -O mk2pylint.cfg -q
- - python2 -m pylint --rcfile=mk2pylint.cfg avent --reports=no || [[ $(($? & 3)) == 0 ]]
+ - python2 -m pylint --rcfile=mk2pylint.cfg avent --reports=no --ignore=fluid.py,strict.py || [[ $(($? & 3)) == 0 ]]
 
 lint:py3:
  stage: test
@@ -54,7 +54,7 @@ lint:py3:
  - linux
  script:
  - wget https://git.mk2es.com.au/snippets/8/raw -O mk2pylint.cfg -q
- - python3 -m pylint --rcfile=mk2pylint.cfg avent --reports=no || [[ $(($? & 3)) == 0 ]]
+ - python3 -m pylint --rcfile=mk2pylint.cfg avent --reports=no --ignore=compat || [[ $(($? & 3)) == 0 ]]
 
 units:
  stage: test
@@ -62,7 +62,7 @@ units:
  - python3
  - linux
  script:
- - python3 -Bm coverage run --source=avent -m unittest tests/*.py
+ - python3 -Bm coverage run --source=avent --omit avent/compat/*.py -m unittest tests/*.py
  - python3 -Bm coverage report -m
 
 deploy:

+ 2 - 2
tests/abject.py

@@ -1,6 +1,6 @@
 import unittest
-from avent.abject import Abject
-from avent.avent_impl import Avent
+from avent import Abject
+from avent import Avent
 
 
 class abj(Abject):

+ 2 - 2
tests/avent_impl.py

@@ -1,6 +1,6 @@
 import unittest, threading
-from avent.avent_impl import Avent
-from avent.abject import Abject
+from avent import Avent
+from avent import Abject
 
 def handler(sender, eargs):
     async, event = eargs

+ 1 - 1
tests/event.py

@@ -1,5 +1,5 @@
 import unittest, threading
-from avent.event import Event
+from avent import Event
 
 
 class Event_test(unittest.TestCase):

+ 1 - 1
tests/fluid.py

@@ -1,5 +1,5 @@
 import unittest
-from avent.fluid import Fluid as Event
+from avent import Fluid as Event
 
 class Fluid_test(unittest.TestCase):
     def test(self):

+ 2 - 2
tests/strict.py

@@ -1,6 +1,6 @@
 import unittest
-from avent.strict import Strict as Event
-from avent.utils import ArgsError
+from avent import Strict as Event
+from avent import ArgsError
 
 
 class Strict_test(unittest.TestCase):