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
414b96f4
Unverified
Commit
414b96f4
authored
Sep 13, 2021
by
Rob
Committed by
GitHub
Sep 13, 2021
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1582 from ethereum/yann300-patch-32
Fixes: Error count in badge in solidity compiler & current file & autocompile in URL params
parents
93bddf61
0052bfe4
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
4 deletions
+13
-4
url.spec.ts
apps/remix-ide-e2e/src/tests/url.spec.ts
+7
-1
compile-tab.js
apps/remix-ide/src/app/tabs/compile-tab.js
+5
-2
compiler-api.ts
apps/solidity-compiler/src/app/compiler-api.ts
+1
-1
No files found.
apps/remix-ide-e2e/src/tests/url.spec.ts
View file @
414b96f4
...
...
@@ -19,10 +19,16 @@ module.exports = {
'Should load the code from URL params (code param)'
:
function
(
browser
:
NightwatchBrowser
)
{
browser
.
waitForElementVisible
(
'[for="autoCompile"]'
)
.
click
(
'[for="autoCompile"]'
)
// we set it too false in the local storage
.
pause
(
5000
)
.
url
(
'http://127.0.0.1:8080/#optimize=true&runs=300&evmVersion=istanbul&version=soljson-v0.7.4+commit.3f05b770.js&code=cHJhZ21hIHNvbGlkaXR5ID49MC42LjAgPDAuNy4wOwoKaW1wb3J0ICJodHRwczovL2dpdGh1Yi5jb20vT3BlblplcHBlbGluL29wZW56ZXBwZWxpbi1jb250cmFjdHMvYmxvYi9tYXN0ZXIvY29udHJhY3RzL2FjY2Vzcy9Pd25hYmxlLnNvbCI7Cgpjb250cmFjdCBHZXRQYWlkIGlzIE93bmFibGUgewogIGZ1bmN0aW9uIHdpdGhkcmF3KCkgZXh0ZXJuYWwgb25seU93bmVyIHsKICB9Cn0'
)
.
url
(
'http://127.0.0.1:8080/#
autoCompile=true&
optimize=true&runs=300&evmVersion=istanbul&version=soljson-v0.7.4+commit.3f05b770.js&code=cHJhZ21hIHNvbGlkaXR5ID49MC42LjAgPDAuNy4wOwoKaW1wb3J0ICJodHRwczovL2dpdGh1Yi5jb20vT3BlblplcHBlbGluL29wZW56ZXBwZWxpbi1jb250cmFjdHMvYmxvYi9tYXN0ZXIvY29udHJhY3RzL2FjY2Vzcy9Pd25hYmxlLnNvbCI7Cgpjb250cmFjdCBHZXRQYWlkIGlzIE93bmFibGUgewogIGZ1bmN0aW9uIHdpdGhkcmF3KCkgZXh0ZXJuYWwgb25seU93bmVyIHsKICB9Cn0'
)
.
refresh
()
// we do one reload for making sure we already have the default workspace
.
pause
(
5000
)
.
verify
.
elementPresent
(
'[data-id="compilerContainerAutoCompile"]:checked'
)
.
click
(
'[for="autoCompile"]'
)
// we set it too false again
.
click
(
'[for="autoCompile"]'
)
// back to True in the local storage
.
assert
.
containsText
(
'*[data-id="compilerContainerCompileBtn"]'
,
'contract-76747f6e19.sol'
)
.
currentWorkspaceIs
(
'code-sample'
)
.
getEditorValue
((
content
)
=>
{
browser
.
assert
.
ok
(
content
.
indexOf
(
...
...
apps/remix-ide/src/app/tabs/compile-tab.js
View file @
414b96f4
...
...
@@ -113,7 +113,7 @@ class CompileTab extends CompilerApiMixin(ViewPlugin) { // implements ICompilerA
return
super
.
compileFile
(
event
)
}
onActivation
()
{
async
onActivation
()
{
super
.
onActivation
()
this
.
call
(
'filePanel'
,
'registerContextMenuItem'
,
{
id
:
'solidity'
,
...
...
@@ -124,6 +124,7 @@ class CompileTab extends CompilerApiMixin(ViewPlugin) { // implements ICompilerA
path
:
[],
pattern
:
[]
})
this
.
currentFile
=
await
this
.
call
(
'fileManager'
,
'file'
)
}
getCompilerParameters
()
{
...
...
@@ -138,7 +139,9 @@ class CompileTab extends CompilerApiMixin(ViewPlugin) { // implements ICompilerA
}
getAppParameter
(
name
)
{
const
param
=
this
.
config
.
get
(
name
)
// first look in the URL params then in the local storage
const
params
=
this
.
queryParams
.
get
()
const
param
=
params
[
name
]
?
params
[
name
]
:
this
.
config
.
get
(
name
)
if
(
param
===
'true'
)
return
true
if
(
param
===
'false'
)
return
false
return
param
...
...
apps/solidity-compiler/src/app/compiler-api.ts
View file @
414b96f4
...
...
@@ -264,7 +264,7 @@ export const CompilerApiMixin = (Base) => class extends Base {
)
})
}
else
{
const
count
=
(
data
.
errors
?
data
.
errors
.
filter
(
error
=>
error
.
severity
===
'error'
).
length
:
0
)
+
data
.
error
?
1
:
0
const
count
=
(
data
.
errors
?
data
.
errors
.
filter
(
error
=>
error
.
severity
===
'error'
).
length
:
0
+
(
data
.
error
?
1
:
0
))
this
.
emit
(
'statusChanged'
,
{
key
:
count
,
title
:
`compilation failed with
${
count
}
error
${
count
>
1
?
's'
:
''
}
`
,
type
:
'error'
})
}
// Update contract Selection
...
...
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