Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
f2b46943
Unverified
Commit
f2b46943
authored
Aug 27, 2020
by
yann300
Committed by
GitHub
Aug 27, 2020
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #377 from ethereum/remix-testsCLI
remix-tests as CLI should work fine
parents
e339feca
0b47f4a8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
run.ts
libs/remix-tests/src/run.ts
+3
-2
runTestFiles.ts
libs/remix-tests/src/runTestFiles.ts
+1
-1
No files found.
libs/remix-tests/src/run.ts
View file @
f2b46943
import
commander
from
'commander'
import
commander
from
'commander'
import
Web3
from
'web3'
;
import
Web3
from
'web3'
;
import
path
from
'path'
import
{
runTestFiles
}
from
'./runTestFiles'
import
{
runTestFiles
}
from
'./runTestFiles'
import
fs
from
'./fileSystem'
import
fs
from
'./fileSystem'
import
{
Provider
}
from
'@remix-project/remix-simulator'
import
{
Provider
}
from
'@remix-project/remix-simulator'
...
@@ -20,7 +21,7 @@ function mapVerbosity (v: number) {
...
@@ -20,7 +21,7 @@ function mapVerbosity (v: number) {
}
}
return
levels
[
v
]
return
levels
[
v
]
}
}
const
version
=
require
(
'../
../../
package.json'
).
version
const
version
=
require
(
'../package.json'
).
version
commander
.
version
(
version
)
commander
.
version
(
version
)
...
@@ -58,7 +59,7 @@ commander
...
@@ -58,7 +59,7 @@ commander
}
}
const
isDirectory
=
fs
.
lstatSync
(
filename
).
isDirectory
()
const
isDirectory
=
fs
.
lstatSync
(
filename
).
isDirectory
()
runTestFiles
(
filename
,
isDirectory
,
web3
)
runTestFiles
(
path
.
resolve
(
filename
)
,
isDirectory
,
web3
)
})
})
if
(
!
process
.
argv
.
slice
(
2
).
length
)
{
if
(
!
process
.
argv
.
slice
(
2
).
length
)
{
...
...
libs/remix-tests/src/runTestFiles.ts
View file @
f2b46943
...
@@ -106,7 +106,7 @@ export function runTestFiles(filepath: string, isDirectory: boolean, web3: Web3,
...
@@ -106,7 +106,7 @@ export function runTestFiles(filepath: string, isDirectory: boolean, web3: Web3,
}
else
if
(
result
.
type
===
'testPass'
)
{
}
else
if
(
result
.
type
===
'testPass'
)
{
signale
.
result
(
result
.
value
)
signale
.
result
(
result
.
value
)
}
else
if
(
result
.
type
===
'testFailure'
)
{
}
else
if
(
result
.
type
===
'testFailure'
)
{
signale
.
result
(
result
.
value
.
red
)
signale
.
error
(
result
.
value
.
red
)
errors
.
push
(
result
)
errors
.
push
(
result
)
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment