mirror of
https://github.com/GSA/notifications-api.git
synced 2026-02-02 09:26:08 -05:00
Adding default values
This commit is contained in:
@@ -361,7 +361,9 @@ class Job(db.Model):
|
|||||||
index=True,
|
index=True,
|
||||||
unique=False,
|
unique=False,
|
||||||
nullable=True)
|
nullable=True)
|
||||||
job_status = db.Column(db.String(255), db.ForeignKey('job_status.name'), index=True, nullable=True)
|
job_status = db.Column(
|
||||||
|
db.String(255), db.ForeignKey('job_status.name'), index=True, nullable=True, default='pending'
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
VERIFY_CODE_TYPES = [EMAIL_TYPE, SMS_TYPE]
|
VERIFY_CODE_TYPES = [EMAIL_TYPE, SMS_TYPE]
|
||||||
|
|||||||
@@ -111,6 +111,8 @@ def test_get_job_by_id(notify_api, sample_job):
|
|||||||
def test_create_job(notify_api, sample_template, mocker, fake_uuid):
|
def test_create_job(notify_api, sample_template, mocker, fake_uuid):
|
||||||
with notify_api.test_request_context():
|
with notify_api.test_request_context():
|
||||||
with notify_api.test_client() as client:
|
with notify_api.test_client() as client:
|
||||||
|
from time import sleep
|
||||||
|
sleep(30)
|
||||||
mocker.patch('app.celery.tasks.process_job.apply_async')
|
mocker.patch('app.celery.tasks.process_job.apply_async')
|
||||||
data = {
|
data = {
|
||||||
'id': fake_uuid,
|
'id': fake_uuid,
|
||||||
|
|||||||
Reference in New Issue
Block a user