Skip to content

Commit

Permalink
<Update>[]: <Update wxPython --> 4.2.1>
Browse files Browse the repository at this point in the history
[
* This update enables using Python 3.11.0
* Fixed deprecated unit test method call
* Updated TestTemplate
]

[#32]
  • Loading branch information
Humberto Sanchez II committed Jun 9, 2023
1 parent de5590a commit b8501f2
Show file tree
Hide file tree
Showing 13 changed files with 41 additions and 48 deletions.
10 changes: 5 additions & 5 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ jobs:
pip install html-testRunner~=1.2.1
pip install attrdict3~=2.0.2
pip install -U -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-22.04 wxPython
pip install hasiihelper~=0.2.0
pip install hasiicommon~=0.2.2
pip install pyutmodel~=1.4.3
pip install ogl~=0.70.40
pip install untanglepyut==0.6.62
pip install hasiihelper~=0.2.1
pip install hasiicommon~=0.3.1
pip install pyutmodel~=1.4.4
pip install ogl~=0.70.52
pip install untanglepyut==0.7.0
pip install buildlackey~=0.8.1
- run:
name: run tests
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@ build/
dist/
oglio.egg-info
/pyenv-3.10.6/
/pyenv-3.11.0/
.envrc
.python-version
2 changes: 1 addition & 1 deletion oglio/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__: str = '0.7.6'
__version__: str = '0.7.7'
20 changes: 9 additions & 11 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,21 +1,19 @@
wheel==0.40.0
setuptools==67.7.2
setuptools==67.8.0
twine==4.0.2
build==0.10.0
html-testRunner~=1.2.1
buildlackey~=0.8.1

mypy==1.3.0
mypy-extensions==1.0.0
typing_extensions==4.5.0
types-setuptools==67.7.0.2
typing_extensions==4.6.3
types-setuptools==67.8.0.0

attrdict3~=2.0.2
wxpython~=4.2.1

wxpython~=4.2.0

hasiihelper==0.2.0
hasiicommon==0.2.2
pyutmodel==1.4.3
ogl==0.70.40
untanglepyut==0.6.62
hasiihelper==0.2.1
hasiicommon==0.3.1
pyutmodel==1.4.4
ogl==0.70.52
untanglepyut==0.7.0
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,6 @@
'oglio': ['py.typed'],
'oglio.toXmlV10': ['py.typed']
},
install_requires=['wxPython==4.2.0', 'hasiihelper~=0.2.0', 'hasiicommon~=0.2.2', 'pyutmodel~=1.4.3', 'ogl==0.70.40', 'untanglepyut==0.6.62',
install_requires=['wxPython==4.2.1', 'hasiihelper~=0.2.1', 'hasiicommon~=0.3.1', 'pyutmodel~=1.4.4', 'ogl==0.70.52', 'untanglepyut==0.7.0',
],
)
11 changes: 5 additions & 6 deletions tests/TestTemplate.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,8 @@

from tests.TestBase import TestBase

"""
import the class you want to test here
"""
# import the class you want to test here
# from org.pyut.template import template


class TestTemplate(TestBase):
Expand All @@ -20,7 +19,7 @@ class TestTemplate(TestBase):
@classmethod
def setUpClass(cls):
super().setUpClass()

def setUp(self):
super().setUp()

Expand All @@ -40,8 +39,8 @@ def suite() -> TestSuite:
import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestTemplate))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestTemplate))

return testSuite

Expand Down
6 changes: 3 additions & 3 deletions tests/oglio/TestReader.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,12 +104,12 @@ def _testDocumentContents(self, oglDocument: OglDocument, expectedClassCount: in


def suite() -> TestSuite:
"""You need to change the name of the test class here also."""

import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestReader))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestReader))

return testSuite

Expand Down
8 changes: 3 additions & 5 deletions tests/oglio/TestWriter.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ def testWriteCompressedFile(self):

TestBase.cleanupGenerated(TestWriter.TEST_COMPRESSED_PROJECT)


def _getTestOglProject(self) -> OglProject:
"""
I need 2 documents with Ogl Objects
Expand All @@ -82,6 +81,7 @@ def _getTestOglProject(self) -> OglProject:
oglProject: OglProject = OglProject()
oglProject.version = OglToDom.VERSION
oglProject.codePath = '/tmp/bogus/Ozzee.py'
# noinspection PyUnusedLocal
generatedFileName: str = TestBase.constructGeneratedName(TestWriter.MULTI_DOCUMENT_FILENAME)

oglDocuments: OglDocuments = createOglDocumentsFactory()
Expand Down Expand Up @@ -111,13 +111,11 @@ def _getTestOglProject(self) -> OglProject:


def suite() -> TestSuite:
"""
"""
import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestWriter))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestWriter))

return testSuite

Expand Down
5 changes: 2 additions & 3 deletions tests/oglio/toXmlV10/TestNotesDiagram.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,12 +71,11 @@ def testNotesSerialization(self):


def suite() -> TestSuite:
"""You need to change the name of the test class here also."""
import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestNotesDiagram))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestNotesDiagram))

return testSuite

Expand Down
5 changes: 2 additions & 3 deletions tests/oglio/toXmlV10/TestOglToDomV10.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,12 +77,11 @@ def testSimpleSerialization(self):


def suite() -> TestSuite:
"""You need to change the name of the test class here also."""
import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestOglToDomV10))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestOglToDomV10))

return testSuite

Expand Down
5 changes: 2 additions & 3 deletions tests/oglio/toXmlV10/TestSequenceDiagram.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,11 @@ def testSequenceDiagramSerialization(self):


def suite() -> TestSuite:
"""You need to change the name of the test class here also."""
import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestSequenceDiagram))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestSequenceDiagram))

return testSuite

Expand Down
5 changes: 2 additions & 3 deletions tests/oglio/toXmlV10/TestUseCaseDiagram.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,11 @@ def testUseCaseSerialization(self):


def suite() -> TestSuite:
"""You need to change the name of the test class here also."""
import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestUseCaseDiagram))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestUseCaseDiagram))

return testSuite

Expand Down
9 changes: 5 additions & 4 deletions tests/oglio/toXmlV11/TestOglToXmlV11.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
USE_CASES_TEXT_NOTES_V11, COMPLEX_SEQUENCE_DIAGRAM_V11,
]


class TestOglToXmlV11(TestBase):
"""
"""
Expand Down Expand Up @@ -91,7 +92,7 @@ def testTextAndLinkedNotes(self):

def testUseCases(self):
"""
Include Text and Notes for completenes
Include Text and Notes for completeness
"""
oglDocument: OglDocument = self._getOglDocument(baseFileName=USE_CASES_TEXT_NOTES_V10, documentName='Use-Cases')
self._assertGeneratedFile(oglDocument=oglDocument, baseFileNameV11=USE_CASES_TEXT_NOTES_V11, assertionMessage='Diff use case serialization failed')
Expand Down Expand Up @@ -137,13 +138,13 @@ def _getOglDocument(self, baseFileName: str, documentName: str) -> OglDocument:

return oglDocument


def suite() -> TestSuite:
"""You need to change the name of the test class here also."""
import unittest

testSuite: TestSuite = TestSuite()
# noinspection PyUnresolvedReferences
testSuite.addTest(unittest.makeSuite(TestOglToXmlV11))

testSuite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(testCaseClass=TestOglToXmlV11))

return testSuite

Expand Down

0 comments on commit b8501f2

Please sign in to comment.