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
4eddeaa4
Commit
4eddeaa4
authored
Aug 19, 2021
by
aniket-engg
Committed by
Aniket
Aug 19, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
log formatting
parent
c31a7f0d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
test-tab.js
apps/remix-ide/src/app/tabs/test-tab.js
+4
-4
No files found.
apps/remix-ide/src/app/tabs/test-tab.js
View file @
4eddeaa4
...
...
@@ -181,7 +181,7 @@ module.exports = class TestTab extends ViewPlugin {
}
printHHLogs
(
logsArr
,
testName
)
{
let
finalLogs
=
`
${
testName
}
:-
\n`
let
finalLogs
=
`
<b>
${
testName
}
:</b>
\n`
for
(
const
log
of
logsArr
)
{
let
formattedLog
// Hardhat implements the same formatting options that can be found in Node.js' console.log,
...
...
@@ -193,7 +193,7 @@ module.exports = class TestTab extends ViewPlugin {
}
else
{
formattedLog
=
log
.
join
(
' '
)
}
finalLogs
=
finalLogs
+
formattedLog
+
'
\
n'
finalLogs
=
finalLogs
+
' '
+
formattedLog
+
'
\
n'
}
this
.
call
(
'terminal'
,
'log'
,
{
type
:
'info'
,
value
:
finalLogs
})
}
...
...
@@ -216,7 +216,7 @@ module.exports = class TestTab extends ViewPlugin {
`
this
.
testsOutput
.
appendChild
(
this
.
outputHeader
)
}
else
if
(
result
.
type
===
'testPass'
)
{
if
(
result
.
hhLogs
&&
result
.
hhLogs
.
length
)
this
.
printHHLogs
(
result
.
hhLogs
,
result
.
value
)
if
(
result
.
hhLogs
&&
result
.
hhLogs
.
length
)
this
.
printHHLogs
(
result
.
hhLogs
,
result
.
value
)
this
.
testsOutput
.
appendChild
(
yo
`
<div
id="
${
this
.
runningTestFileName
}
"
...
...
@@ -228,7 +228,7 @@ module.exports = class TestTab extends ViewPlugin {
</div>
`
)
}
else
if
(
result
.
type
===
'testFailure'
)
{
if
(
result
.
hhLogs
&&
result
.
hhLogs
.
length
)
this
.
printHHLogs
(
result
.
hhLogs
,
result
.
value
)
if
(
result
.
hhLogs
&&
result
.
hhLogs
.
length
)
this
.
printHHLogs
(
result
.
hhLogs
,
result
.
value
)
if
(
!
result
.
assertMethod
)
{
this
.
testsOutput
.
appendChild
(
yo
`
<div
...
...
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