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
a25678ec
Commit
a25678ec
authored
Aug 12, 2020
by
ioedeveloper
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed failing tests
parent
1004777f
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
6 deletions
+15
-6
getAddressAtPosition.ts
apps/remix-ide-e2e/src/commands/getAddressAtPosition.ts
+5
-3
getEditorValue.ts
apps/remix-ide-e2e/src/commands/getEditorValue.ts
+4
-2
getModalBody.ts
apps/remix-ide-e2e/src/commands/getModalBody.ts
+3
-1
libraryDeployment.test.ts
apps/remix-ide-e2e/src/tests/libraryDeployment.test.ts
+3
-0
No files found.
apps/remix-ide-e2e/src/commands/getAddressAtPosition.ts
View file @
a25678ec
...
@@ -4,7 +4,7 @@ import EventEmitter from "events"
...
@@ -4,7 +4,7 @@ import EventEmitter from "events"
class
GetAddressAtPosition
extends
EventEmitter
{
class
GetAddressAtPosition
extends
EventEmitter
{
command
(
this
:
NightwatchBrowser
,
index
:
number
,
cb
:
(
pos
:
string
)
=>
void
):
NightwatchBrowser
{
command
(
this
:
NightwatchBrowser
,
index
:
number
,
cb
:
(
pos
:
string
)
=>
void
):
NightwatchBrowser
{
this
.
api
.
perform
((
done
)
=>
{
this
.
api
.
perform
((
done
)
=>
{
getAddressAtPosition
(
this
.
api
,
index
,
(
pos
:
string
)
=>
{
getAddressAtPosition
(
this
.
api
,
index
,
(
pos
)
=>
{
done
()
done
()
cb
(
pos
)
cb
(
pos
)
this
.
emit
(
'complete'
)
this
.
emit
(
'complete'
)
...
@@ -14,7 +14,7 @@ class GetAddressAtPosition extends EventEmitter {
...
@@ -14,7 +14,7 @@ class GetAddressAtPosition extends EventEmitter {
}
}
}
}
function
getAddressAtPosition
(
browser
:
NightwatchBrowser
,
index
:
number
,
callback
:
(
pos
:
any
)
=>
void
)
{
function
getAddressAtPosition
(
browser
:
NightwatchBrowser
,
index
:
number
,
callback
:
(
pos
:
string
)
=>
void
)
{
browser
.
waitForElementPresent
(
'*[data-shared="universalDappUiInstance"]'
)
browser
.
waitForElementPresent
(
'*[data-shared="universalDappUiInstance"]'
)
.
execute
(
function
(
index
)
{
.
execute
(
function
(
index
)
{
const
deployedContracts
=
document
.
querySelectorAll
(
'*[data-shared="universalDappUiInstance"]'
)
const
deployedContracts
=
document
.
querySelectorAll
(
'*[data-shared="universalDappUiInstance"]'
)
...
@@ -22,7 +22,9 @@ function getAddressAtPosition (browser: NightwatchBrowser, index: number, callba
...
@@ -22,7 +22,9 @@ function getAddressAtPosition (browser: NightwatchBrowser, index: number, callba
return
id
.
replace
(
'instance'
,
''
)
return
id
.
replace
(
'instance'
,
''
)
},
[
index
],
function
(
result
)
{
},
[
index
],
function
(
result
)
{
callback
(
result
.
value
)
const
pos
=
typeof
result
.
value
===
'string'
?
result
.
value
:
null
callback
(
pos
)
})
})
}
}
...
...
apps/remix-ide-e2e/src/commands/getEditorValue.ts
View file @
a25678ec
...
@@ -7,10 +7,12 @@ class GetEditorValue extends EventEmitter {
...
@@ -7,10 +7,12 @@ class GetEditorValue extends EventEmitter {
this
.
api
.
execute
(
function
()
{
this
.
api
.
execute
(
function
()
{
const
elem
:
any
=
document
.
getElementById
(
'input'
)
const
elem
:
any
=
document
.
getElementById
(
'input'
)
elem
.
editor
.
getValue
()
return
elem
.
editor
.
getValue
()
},
[],
(
result
)
=>
{
},
[],
(
result
)
=>
{
done
()
done
()
typeof
result
.
value
===
'string'
&&
callback
(
result
.
value
)
const
value
=
typeof
result
.
value
===
'string'
?
result
.
value
:
null
callback
(
value
)
this
.
emit
(
'complete'
)
this
.
emit
(
'complete'
)
})
})
})
})
...
...
apps/remix-ide-e2e/src/commands/getModalBody.ts
View file @
a25678ec
...
@@ -6,7 +6,9 @@ class GetModalBody extends EventEmitter {
...
@@ -6,7 +6,9 @@ class GetModalBody extends EventEmitter {
this
.
api
.
waitForElementVisible
(
'.modal-body'
)
this
.
api
.
waitForElementVisible
(
'.modal-body'
)
.
getText
(
'.modal-body'
,
(
result
)
=>
{
.
getText
(
'.modal-body'
,
(
result
)
=>
{
console
.
log
(
result
)
console
.
log
(
result
)
typeof
result
.
value
===
'string'
&&
callback
(
result
.
value
,
()
=>
{
const
value
=
typeof
result
.
value
===
'string'
?
result
.
value
:
null
callback
(
value
,
()
=>
{
this
.
emit
(
'complete'
)
this
.
emit
(
'complete'
)
})
})
})
})
...
...
apps/remix-ide-e2e/src/tests/libraryDeployment.test.ts
View file @
a25678ec
...
@@ -76,6 +76,9 @@ function checkDeployShouldFail (browser: NightwatchBrowser, callback: VoidFuncti
...
@@ -76,6 +76,9 @@ function checkDeployShouldFail (browser: NightwatchBrowser, callback: VoidFuncti
.
openFile
(
'browser/Untitled5.sol'
)
.
openFile
(
'browser/Untitled5.sol'
)
.
selectContract
(
'test'
)
// deploy lib
.
selectContract
(
'test'
)
// deploy lib
.
createContract
(
''
)
.
createContract
(
''
)
.
getText
(
'div[class^="terminal"]'
,
(
value
)
=>
{
console
.
log
(
'value: '
,
value
)
})
.
assert
.
containsText
(
'div[class^="terminal"]'
,
'<address> is not a valid address'
)
.
assert
.
containsText
(
'div[class^="terminal"]'
,
'<address> is not a valid address'
)
.
perform
(()
=>
{
callback
()
})
.
perform
(()
=>
{
callback
()
})
}
}
...
...
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