Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
exchain
nebula
Commits
81d7a4ef
Unverified
Commit
81d7a4ef
authored
Jul 26, 2023
by
mergify[bot]
Committed by
GitHub
Jul 26, 2023
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' into refcell/network-type
parents
21859d61
1b87e2b4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
12 deletions
+11
-12
system_test.go
op-e2e/system_test.go
+11
-12
No files found.
op-e2e/system_test.go
View file @
81d7a4ef
...
@@ -1351,22 +1351,21 @@ func TestBatcherMultiTx(t *testing.T) {
...
@@ -1351,22 +1351,21 @@ func TestBatcherMultiTx(t *testing.T) {
err
=
sys
.
BatchSubmitter
.
Start
()
err
=
sys
.
BatchSubmitter
.
Start
()
require
.
Nil
(
t
,
err
)
require
.
Nil
(
t
,
err
)
// wait for 3 L1 blocks
_
,
err
=
waitForBlock
(
big
.
NewInt
(
int64
(
l1Number
)
+
3
),
l1Client
,
time
.
Duration
(
cfg
.
DeployConfig
.
L1BlockTime
*
5
)
*
time
.
Second
)
require
.
Nil
(
t
,
err
,
"Waiting for l1 blocks"
)
// count the number of transactions submitted to L1 in the last 3 blocks
ctx
,
cancel
=
context
.
WithTimeout
(
context
.
Background
(),
10
*
time
.
Second
)
defer
cancel
()
totalTxCount
:=
0
totalTxCount
:=
0
for
i
:=
int64
(
0
);
i
<
3
;
i
++
{
// wait for up to 10 L1 blocks, usually only 3 is required, but it's
block
,
err
:=
l1Client
.
BlockByNumber
(
ctx
,
big
.
NewInt
(
int64
(
l1Number
)
+
i
+
1
))
// possible additional L1 blocks will be created before the batcher starts,
require
.
Nil
(
t
,
err
)
// so we wait additional blocks.
for
i
:=
int64
(
0
);
i
<
10
;
i
++
{
block
,
err
:=
waitForBlock
(
big
.
NewInt
(
int64
(
l1Number
)
+
i
),
l1Client
,
time
.
Duration
(
cfg
.
DeployConfig
.
L1BlockTime
*
5
)
*
time
.
Second
)
require
.
Nil
(
t
,
err
,
"Waiting for l1 blocks"
)
totalTxCount
+=
len
(
block
.
Transactions
())
totalTxCount
+=
len
(
block
.
Transactions
())
if
totalTxCount
>=
10
{
return
}
}
}
// expect at least 10 batcher transactions, given 10 L2 blocks were generated above
t
.
Fatal
(
"Expected at least 10 transactions from the batcher"
)
require
.
GreaterOrEqual
(
t
,
totalTxCount
,
10
)
}
}
func
safeAddBig
(
a
*
big
.
Int
,
b
*
big
.
Int
)
*
big
.
Int
{
func
safeAddBig
(
a
*
big
.
Int
,
b
*
big
.
Int
)
*
big
.
Int
{
...
...
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