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
bf7f81a9
Unverified
Commit
bf7f81a9
authored
Dec 22, 2023
by
Hamdi Allam
Committed by
GitHub
Dec 23, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bump up block times (#8761)
parent
85dfe654
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
10 deletions
+13
-10
setup.go
indexer/e2e_tests/setup.go
+13
-10
No files found.
indexer/e2e_tests/setup.go
View file @
bf7f81a9
...
@@ -52,22 +52,27 @@ type E2ETestSuite struct {
...
@@ -52,22 +52,27 @@ type E2ETestSuite struct {
L2Client
*
ethclient
.
Client
L2Client
*
ethclient
.
Client
}
}
func
init
()
{
log
.
Root
()
.
SetHandler
(
log
.
DiscardHandler
())
}
// createE2ETestSuite ... Create a new E2E test suite
// createE2ETestSuite ... Create a new E2E test suite
func
createE2ETestSuite
(
t
*
testing
.
T
)
E2ETestSuite
{
func
createE2ETestSuite
(
t
*
testing
.
T
)
E2ETestSuite
{
dbUser
:=
os
.
Getenv
(
"DB_USER"
)
dbUser
:=
os
.
Getenv
(
"DB_USER"
)
dbName
:=
setupTestDatabase
(
t
)
dbName
:=
setupTestDatabase
(
t
)
// E2E tests can run on the order of magnitude of minutes. Once
// E2E tests can run on the order of magnitude of minutes.
// the system is running, mark this test for Parallel execution.
// We mark the test as parallel before starting the devnet
// We mark the test as parallel before starting the devnet to
// to reduce that number of idle routines when paused.
// reduce that number of idle routines when paused.
t
.
Parallel
()
t
.
Parallel
()
// Rollup System Configuration. Unless specified,
// Bump up the block times to try minimize resource
// omit logs emitted by the various components. Maybe
// contention when parallel devnets are running
// we can eventually dump these logs to a temp file
log
.
Root
()
.
SetHandler
(
log
.
DiscardHandler
())
opCfg
:=
op_e2e
.
DefaultSystemConfig
(
t
)
opCfg
:=
op_e2e
.
DefaultSystemConfig
(
t
)
opCfg
.
DeployConfig
.
L1BlockTime
=
6
opCfg
.
DeployConfig
.
L2BlockTime
=
2
// Unless specified, omit logs emitted by the various components
if
len
(
os
.
Getenv
(
"ENABLE_ROLLUP_LOGS"
))
==
0
{
if
len
(
os
.
Getenv
(
"ENABLE_ROLLUP_LOGS"
))
==
0
{
t
.
Log
(
"set env 'ENABLE_ROLLUP_LOGS' to show rollup logs"
)
t
.
Log
(
"set env 'ENABLE_ROLLUP_LOGS' to show rollup logs"
)
for
name
:=
range
opCfg
.
Loggers
{
for
name
:=
range
opCfg
.
Loggers
{
...
@@ -116,7 +121,6 @@ func createE2ETestSuite(t *testing.T) E2ETestSuite {
...
@@ -116,7 +121,6 @@ func createE2ETestSuite(t *testing.T) E2ETestSuite {
})
})
require
.
NoError
(
t
,
err
)
require
.
NoError
(
t
,
err
)
require
.
NoError
(
t
,
ix
.
Start
(
context
.
Background
()),
"cleanly start indexer"
)
require
.
NoError
(
t
,
ix
.
Start
(
context
.
Background
()),
"cleanly start indexer"
)
t
.
Cleanup
(
func
()
{
t
.
Cleanup
(
func
()
{
require
.
NoError
(
t
,
ix
.
Stop
(
context
.
Background
()),
"cleanly shut down indexer"
)
require
.
NoError
(
t
,
ix
.
Stop
(
context
.
Background
()),
"cleanly shut down indexer"
)
})
})
...
@@ -131,7 +135,6 @@ func createE2ETestSuite(t *testing.T) E2ETestSuite {
...
@@ -131,7 +135,6 @@ func createE2ETestSuite(t *testing.T) E2ETestSuite {
apiService
,
err
:=
api
.
NewApi
(
context
.
Background
(),
apiLog
,
apiCfg
)
apiService
,
err
:=
api
.
NewApi
(
context
.
Background
(),
apiLog
,
apiCfg
)
require
.
NoError
(
t
,
err
,
"create indexer API service"
)
require
.
NoError
(
t
,
err
,
"create indexer API service"
)
require
.
NoError
(
t
,
apiService
.
Start
(
context
.
Background
()),
"start indexer API service"
)
require
.
NoError
(
t
,
apiService
.
Start
(
context
.
Background
()),
"start indexer API service"
)
t
.
Cleanup
(
func
()
{
t
.
Cleanup
(
func
()
{
require
.
NoError
(
t
,
apiService
.
Stop
(
context
.
Background
()),
"cleanly shut down indexer"
)
require
.
NoError
(
t
,
apiService
.
Stop
(
context
.
Background
()),
"cleanly shut down indexer"
)
...
...
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