From e4f463d52c0ae0cc9a01756253ca9f94e486ce8c Mon Sep 17 00:00:00 2001 From: Danimar Ribeiro Date: Mon, 15 Jun 2015 00:04:36 -0300 Subject: [PATCH] Corrigido nome dos testes --- pytrustnfe/__init__.py | 1 + pytrustnfe/servicos/__init__.py | 2 ++ test/__init__.py | 1 + test/test_assinatura.py | 31 +++++++++++++++++++++++++++++++ tests/AssinaturaTest.py | 31 ------------------------------- tests/__init__.py | 0 6 files changed, 35 insertions(+), 31 deletions(-) create mode 100644 test/__init__.py create mode 100644 test/test_assinatura.py delete mode 100644 tests/AssinaturaTest.py delete mode 100644 tests/__init__.py diff --git a/pytrustnfe/__init__.py b/pytrustnfe/__init__.py index e69de29..daebf5d 100644 --- a/pytrustnfe/__init__.py +++ b/pytrustnfe/__init__.py @@ -0,0 +1 @@ +import servicos diff --git a/pytrustnfe/servicos/__init__.py b/pytrustnfe/servicos/__init__.py index e69de29..95b522b 100644 --- a/pytrustnfe/servicos/__init__.py +++ b/pytrustnfe/servicos/__init__.py @@ -0,0 +1,2 @@ +import assinatura +import comunicacao \ No newline at end of file diff --git a/test/__init__.py b/test/__init__.py new file mode 100644 index 0000000..c33e53e --- /dev/null +++ b/test/__init__.py @@ -0,0 +1 @@ +import test_assinatura \ No newline at end of file diff --git a/test/test_assinatura.py b/test/test_assinatura.py new file mode 100644 index 0000000..e261e49 --- /dev/null +++ b/test/test_assinatura.py @@ -0,0 +1,31 @@ +#coding=utf-8 +''' +Created on Jun 14, 2015 + +@author: danimar +''' +import unittest +from pytrustnfe.servicos.assinatura import Assinatura + +XML_ASSINAR = '' \ + '' \ + ' ' \ + ' Hello, World!' \ + ' ' \ + '' + +XML_ASSINADO = '' + +class test_assinatura(unittest.TestCase): + + def test_assinar_xml(self): + print 'oola' + assinatura = Assinatura('/home/danimar/Desktop/INFOGER.pfx', '123456') + + self.assertRaises(RuntimeError, assinatura.assina_xml, XML_ASSINAR) + + +#if __name__ == "__main__": + #import sys;sys.argv = ['', 'Test.testName'] +# unittest.main() + \ No newline at end of file diff --git a/tests/AssinaturaTest.py b/tests/AssinaturaTest.py deleted file mode 100644 index 4127e7f..0000000 --- a/tests/AssinaturaTest.py +++ /dev/null @@ -1,31 +0,0 @@ -#coding=utf-8 -''' -Created on Jun 14, 2015 - -@author: danimar -''' -import unittest -from pytrustnfe.servicos.assinatura import Assinatura - -XML_ASSINAR = '' \ - '' \ - ' ' \ - ' Hello, World!' \ - ' ' \ - '' - -XML_ASSINADO = '' - -class Test(unittest.TestCase): - - def testAssinarXml(self): - - assinatura = Assinatura('/home/danimar/Desktop/INFOGER.pfx', '123456') - - self.assertRaises(RuntimeError, assinatura.assina_xml, XML_ASSINAR) - - -if __name__ == "__main__": - #import sys;sys.argv = ['', 'Test.testName'] - unittest.main() - \ No newline at end of file diff --git a/tests/__init__.py b/tests/__init__.py deleted file mode 100644 index e69de29..0000000