Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
John McEleney
/
casperjs
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit
e7eaeea1
...
e7eaeea1cdaf222d31c0fd4a791cf0b658fd7319
authored
2013-02-17 23:16:17 -0800
by
Nicolas Perriault
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge pull request #386 from p/python-open
Close package.json after using it
2 parents
661c77ec
95456d33
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
1 deletions
bin/casperjs
bin/casperjs
View file @
e7eaeea
...
...
@@ -47,7 +47,8 @@ SYS_ARGS = sys.argv[1:]
if
len
(
SYS_ARGS
)
and
SYS_ARGS
[
0
]
==
'__selfcommandtest'
:
print
(
'Starting Python executable tests...'
)
pkg_version
=
json
.
loads
(
open
(
'package.json'
)
.
read
())
.
get
(
'version'
)
with
open
(
'package.json'
)
as
f
:
pkg_version
=
json
.
load
(
f
)
.
get
(
'version'
)
scripts_path
=
os
.
path
.
join
(
CASPER_PATH
,
'tests'
,
'commands'
)
assert
(
test_cmd
(
'--help'
)
.
find
(
pkg_version
)
>
-
1
)
assert
(
test_cmd
(
'--version'
)
.
strip
()
==
pkg_version
)
...
...
Please
register
or
sign in
to post a comment