fix travis tests

pull/201/head
Terrtia 2018-04-26 16:54:42 +02:00
parent c3428df5dc
commit daae351411
3 changed files with 31 additions and 7 deletions

View File

@ -24,8 +24,8 @@ script:
- ./launch_lvldb.sh
- ./launch_logs.sh
- ./launch_queues.sh
- nosetests --with-coverage --cover-package=bin -d
- ls
- cd tests
- nosetests --with-coverage --cover-package=../bin -d
after_success:

22
tests/testHelper.py Normal file
View File

@ -0,0 +1,22 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import unittest
import sys,os
sys.path.append(os.environ['AIL_BIN'])
from Helper import Process
class TestHelper(unittest.TestCase):
def setUp(self):
config_section = 'Keys'
def test_Process_Constructor_using_key_module(self):
conf_section = 'Keys'
process = Process(conf_section)
self.assertEqual(process.subscriber_name, 'Keys')

View File

@ -1,20 +1,22 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import sys,os
import unittest
import magic
from bin.packages.Paste import Paste
import bin.Keys as Keys
from bin.Helper import Process
sys.path.append(os.environ['AIL_BIN'])
from packages.Paste import Paste
import Keys as Keys
from Helper import Process
import pubsublogger
class TestKeysModule(unittest.TestCase):
def setUp(self):
self.paste = Paste('samples/2018/01/01/keys_certificat_sample.gz')
self.paste = Paste('../samples/2018/01/01/keys_certificat_sample.gz')
# Section name in bin/packages/modules.cfg
self.config_section = 'Keys'