File tree 3 files changed +21
-10
lines changed
3 files changed +21
-10
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ install:
10
10
- python -m pip install --upgrade pip
11
11
- pip install --upgrade -r requirements.txt
12
12
script :
13
+ - export ANDROID_HOME=$HOME
13
14
- python -m nose core_tests/unit
14
15
- python -m flake8 --max-line-length=120 core core_tests data products tests
15
16
- python -m pylint --disable=locally-disabled --rcfile=.pylintrc core data products
Original file line number Diff line number Diff line change
1
+ import os
2
+ import unittest
3
+
4
+ from core .utils .file_utils import File
5
+ from products .nativescript .preview_helpers import Preview
6
+
7
+
8
+ # noinspection PyMethodMayBeStatic
9
+ class PreviewHelperTests (unittest .TestCase ):
10
+ current_folder = os .path .dirname (os .path .realpath (__file__ ))
11
+
12
+ def test_01_constants (self ):
13
+ text = File .read (path = os .path .join (self .current_folder , 'preview.log' ))
14
+ url = Preview .get_url (output = text )
15
+ assert 'nsplay://boot\\ ?instanceId=' in url
16
+
17
+
18
+ if __name__ == '__main__' :
19
+ unittest .main ()
Original file line number Diff line number Diff line change 3
3
4
4
from core .enums .platform_type import Platform
5
5
from core .settings import Settings
6
- from core .utils .file_utils import File
7
6
from data .changes import Changes
8
- from products .nativescript .preview_helpers import Preview
9
7
from products .nativescript .run_type import RunType
10
8
from products .nativescript .tns_logs import TnsLogs
11
9
12
10
13
11
# noinspection PyMethodMayBeStatic
14
- class TnsHelpersTests (unittest .TestCase ):
12
+ class SyncMessagesTests (unittest .TestCase ):
15
13
16
14
def test_01_constants (self ):
17
15
assert len (TnsLogs .SKIP_NODE_MODULES ) == 2
@@ -160,13 +158,6 @@ def test_18_get_run_messages_incremental_prepare(self):
160
158
assert 'Skipping prepare.' not in logs
161
159
assert 'Successfully transferred main-view-model.js' in logs
162
160
163
- @unittest .skipIf (os .environ .get ('TRAVIS' , None ) is not None , 'Skip on Travis.' )
164
- def test_40_get_preview_url (self ):
165
- current_folder = os .path .dirname (os .path .realpath (__file__ ))
166
- text = File .read (path = os .path .join (current_folder , 'preview.log' ))
167
- url = Preview .get_url (output = text )
168
- assert 'nsplay://boot\\ ?instanceId=' in url
169
-
170
161
171
162
if __name__ == '__main__' :
172
163
unittest .main ()
You can’t perform that action at this time.
0 commit comments