Skip to content
This repository has been archived by the owner on Jul 15, 2020. It is now read-only.

Commit

Permalink
Clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
dbazile committed Feb 8, 2017
1 parent 1d995f3 commit 24d15d4
Show file tree
Hide file tree
Showing 6 changed files with 59 additions and 79 deletions.
4 changes: 2 additions & 2 deletions test/db/test_init.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,12 @@ def setUp(self):
self.conn = unittest.mock.Mock()

def test_does_things(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class InstallTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_does_things(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
78 changes: 39 additions & 39 deletions test/db/test_jobs.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,178 +21,178 @@ def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class ExistsTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class InsertDetectionTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class InsertJobTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class InsertJobFailureTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class InsertJobUserTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class SelectJobTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class SelectJobsForInputsTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class SelectJobsForProductlineTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class SelectJobsForSceneTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class SelectJobsForUserTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class SelectSummaryForStatusTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class UpdateStatusTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
12 changes: 6 additions & 6 deletions test/db/test_productlines.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,19 +20,19 @@ class InsertProductLineTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()
def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
def test_throws_when_execution_fails(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class InsertProductLineJobTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()
def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
def test_throws_when_execution_fails(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
6 changes: 3 additions & 3 deletions test/db/test_scenes.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
18 changes: 9 additions & 9 deletions test/db/test_users.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,38 +21,38 @@ def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class SelectUserByApiKeyTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')


class InsertOrUpdateUserTest(unittest.TestCase):
def setUp(self):
self.conn = unittest.mock.Mock()

def test_sends_correct_query(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_sends_correct_parameters(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')

def test_throws_when_connection_throws(self):
self.skipTest('Not implemented')
self.skipTest('Not yet implemented')
20 changes: 0 additions & 20 deletions test/service/test_productlines.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
from bfapi.db import DatabaseError
from bfapi.service import productlines
from bfapi.service.algorithms import Algorithm, NotFound, ValidationError
from bfapi.service.jobs import Job

DATE_START = datetime.utcfromtimestamp(1400000000)
DATE_STOP = datetime.utcfromtimestamp(1500000000)
Expand Down Expand Up @@ -463,25 +462,6 @@ def create_algorithm():
)


def create_job(job_id: str = 'test-job-id'):
return Job(
algorithm_name='test-algo-name',
algorithm_version='test-algo-version',
created_by='test-created-by',
created_on=datetime.utcnow(),
geometry={},
job_id=job_id,
name='test-job-name',
time_of_collect=datetime.utcnow(),
scene_sensor_name='test-scene-sensor-name',
scene_id='test-scene-id',
status='test-status',
tide=5.4321,
tide_min_24h=-10.0,
tide_max_24h=10.0,
)


def create_productline_db_record(record_id: str = 'test-productline-id'):
return {
'productline_id': record_id,
Expand Down

0 comments on commit 24d15d4

Please sign in to comment.