Skip to content

Commit

Permalink
Python support: partially reverted commit ea352e4 (#2178).
Browse files Browse the repository at this point in the history
Indeed, we could (obviously!) not run our script from the Python Console window, only from the command line.
  • Loading branch information
agarny committed Dec 10, 2019
1 parent 04951dd commit 2f37e07
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/plugins/support/PythonSupport/tests/data/basictests.py
@@ -1,5 +1,7 @@
import opencor as oc

from math import floor
from os import path


def header(title, first):
Expand All @@ -15,7 +17,7 @@ def open_simulation(file_name_or_url):
if file_name_or_url.startswith('https://'):
return oc.open_simulation(file_name_or_url)
else:
return oc.open_simulation('models/tests/' + file_name_or_url)
return oc.open_simulation(path.dirname(__file__) + '/../../../../../../models/tests/' + file_name_or_url)


def print_values(data):
Expand Down

0 comments on commit 2f37e07

Please sign in to comment.