Fix: use relative file path

This commit is contained in:
Arik Fraimovich 2014-03-11 19:15:44 +02:00
parent 417571ecd6
commit 5df3dbde1a

View File

@ -1,4 +1,5 @@
import json
import os.path
from tests import BaseTestCase
from redash import models
from redash import import_export
@ -9,7 +10,7 @@ class ImportTest(BaseTestCase):
def setUp(self):
super(ImportTest, self).setUp()
with open('flights.json') as f:
with open(os.path.join(os.path.dirname(__file__), 'flights.json')) as f:
self.dashboard = json.loads(f.read())
self.user = user_factory.create()