Skip to content

Commit a5bc939

Browse files
authored
fix: tns_assert.py (#21)
1 parent 48d9041 commit a5bc939

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

products/nativescript/tns_assert.py

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -36,19 +36,19 @@ def created(app_name, output=None, app_data=None):
3636
assert Folder.exists(os.path.join(app_path, TnsAssert.NODE_MODULES, 'nativescript-theme-core'))
3737
assert Folder.exists(os.path.join(app_path, TnsAssert.NODE_MODULES, 'nativescript-dev-webpack'))
3838

39-
if app_data.type is AppType.JS:
39+
if app_data.app_type is AppType.JS:
4040
pass
41-
elif app_data.type is AppType.TS:
41+
elif app_data.app_type is AppType.TS:
4242
TnsAssert.__verify_created_ts()
43-
elif app_data.type is AppType.NG:
43+
elif app_data.app_type is AppType.NG:
4444
TnsAssert.__verify_created_ng()
45-
elif app_data.type is AppType.VUE:
45+
elif app_data.app_type is AppType.VUE:
4646
pass
47-
elif app_data.type is AppType.SHARED_NG:
47+
elif app_data.app_type is AppType.SHARED_NG:
4848
pass
4949

5050
# Assert app id
51-
if app_data.id is not None:
51+
if app_data.app_id is not None:
5252
pass
5353

5454
# Assert size
@@ -70,6 +70,7 @@ def platform_added(app_name, platform, output):
7070
assert json['nativescript']['tns-' + platform_string]['version'] is not None, \
7171
'tns-' + platform_string + ' not available in package.json of the app.'
7272

73+
# noinspection PyUnusedLocal
7374
@staticmethod
7475
def build(app_name, platform=None, release=False, provision=Settings.IOS.DEV_PROVISION, for_device=False,
7576
bundle=False, aot=False, uglify=False, snapshot=False, log_trace=False, output=None, app_data=None):
@@ -82,13 +83,13 @@ def build(app_name, platform=None, release=False, provision=Settings.IOS.DEV_PRO
8283
# Assert app data
8384
if app_data is not None:
8485
# Assert app type
85-
if app_data.type is AppType.JS:
86+
if app_data.app_type is AppType.JS:
8687
pass
87-
elif app_data.type is AppType.TS:
88+
elif app_data.app_type is AppType.TS:
8889
pass
89-
elif app_data.type is AppType.NG:
90+
elif app_data.app_type is AppType.NG:
9091
pass
91-
elif app_data.type is AppType.SHARED_NG:
92+
elif app_data.app_type is AppType.SHARED_NG:
9293
pass
9394

9495
# Assert size

0 commit comments

Comments
 (0)