Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
Grpc
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
tci-gateway-module
Grpc
Commits
38fb8de1
Commit
38fb8de1
authored
8 years ago
by
Craig Tiller
Browse files
Options
Downloads
Patches
Plain Diff
get timeouts working on run_tests.py again
parent
e64d6930
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
test/cpp/qps/gen_build_yaml.py
+3
-2
3 additions, 2 deletions
test/cpp/qps/gen_build_yaml.py
tools/run_tests/run_tests.py
+14
-6
14 additions, 6 deletions
tools/run_tests/run_tests.py
tools/run_tests/tests.json
+48
-32
48 additions, 32 deletions
tools/run_tests/tests.json
with
65 additions
and
40 deletions
test/cpp/qps/gen_build_yaml.py
+
3
−
2
View file @
38fb8de1
...
...
@@ -45,7 +45,7 @@ import performance.scenario_config as scenario_config
def
_scenario_json_string
(
scenario_json
):
# tweak parameters to get fast test times
scenario_json
[
'
warmup_seconds
'
]
=
1
scenario_json
[
'
warmup_seconds
'
]
=
0
scenario_json
[
'
benchmark_seconds
'
]
=
1
scenarios_json
=
{
'
scenarios
'
:
[
scenario_config
.
remove_nonproto_fields
(
scenario_json
)]}
return
json
.
dumps
(
scenarios_json
)
...
...
@@ -81,7 +81,8 @@ print yaml.dump({
'
boringssl
'
:
True
,
'
defaults
'
:
'
boringssl
'
,
'
cpu_cost
'
:
guess_cpu
(
scenario_json
),
'
exclude_configs
'
:
[]
'
exclude_configs
'
:
[],
'
timeout_seconds
'
:
15
}
for
scenario_json
in
scenario_config
.
CXXLanguage
().
scenarios
()
]
...
...
This diff is collapsed.
Click to expand it.
tools/run_tests/run_tests.py
+
14
−
6
View file @
38fb8de1
...
...
@@ -39,6 +39,7 @@ import json
import
multiprocessing
import
os
import
os.path
import
pipes
import
platform
import
random
import
re
...
...
@@ -72,6 +73,9 @@ def platform_string():
return
jobset
.
platform_string
()
_DEFAULT_TIMEOUT_SECONDS
=
5
*
60
# SimpleConfig: just compile with CONFIG=config, and run the binary to test
class
Config
(
object
):
...
...
@@ -84,7 +88,7 @@ class Config(object):
self
.
tool_prefix
=
tool_prefix
self
.
timeout_multiplier
=
timeout_multiplier
def
job_spec
(
self
,
cmdline
,
timeout_seconds
=
5
*
60
,
def
job_spec
(
self
,
cmdline
,
timeout_seconds
=
_DEFAULT_TIMEOUT_SECONDS
,
shortname
=
None
,
environ
=
{},
cpu_cost
=
1.0
,
flaky
=
False
):
"""
Construct a jobset.JobSpec for a test under this config
...
...
@@ -159,7 +163,7 @@ class CLanguage(object):
env
=
{
'
GRPC_DEFAULT_SSL_ROOTS_FILE_PATH
'
:
_ROOT
+
'
/src/core/lib/tsi/test_creds/ca.pem
'
,
'
GRPC_POLL_STRATEGY
'
:
polling_strategy
}
shortname_ext
=
''
if
polling_strategy
==
'
all
'
else
'
polling
=%s
'
%
polling_strategy
shortname_ext
=
''
if
polling_strategy
==
'
all
'
else
'
GRPC_POLL_STRATEGY
=%s
'
%
polling_strategy
if
self
.
config
.
build_config
in
target
[
'
exclude_configs
'
]:
continue
if
self
.
platform
==
'
windows
'
:
...
...
@@ -190,16 +194,20 @@ class CLanguage(object):
assert
line
[
1
]
==
'
'
test
=
base
+
line
.
strip
()
cmdline
=
[
binary
]
+
[
'
--gtest_filter=%s
'
%
test
]
out
.
append
(
self
.
config
.
job_spec
(
cmdline
,
[
binary
],
shortname
=
'
%s
:
%s %s
'
%
(
binary
,
test
,
shortname_ext
),
out
.
append
(
self
.
config
.
job_spec
(
cmdline
,
shortname
=
'
%s
--gtest_filter=
%s %s
'
%
(
binary
,
test
,
shortname_ext
),
cpu_cost
=
target
[
'
cpu_cost
'
],
environ
=
env
))
else
:
cmdline
=
[
binary
]
+
target
[
'
args
'
]
out
.
append
(
self
.
config
.
job_spec
(
cmdline
,
[
binary
],
shortname
=
'
'
.
join
(
cmdline
)
+
shortname_ext
,
out
.
append
(
self
.
config
.
job_spec
(
cmdline
,
shortname
=
'
'
.
join
(
pipes
.
quote
(
arg
)
for
arg
in
cmdline
)
+
shortname_ext
,
cpu_cost
=
target
[
'
cpu_cost
'
],
flaky
=
target
.
get
(
'
flaky
'
,
False
),
timeout_seconds
=
target
.
get
(
'
timeout_seconds
'
,
_DEFAULT_TIMEOUT_SECONDS
),
environ
=
env
))
elif
self
.
args
.
regex
==
'
.*
'
or
self
.
platform
==
'
windows
'
:
print
'
\n
WARNING: binary not found, skipping
'
,
binary
...
...
This diff is collapsed.
Click to expand it.
tools/run_tests/tests.json
+
48
−
32
View file @
38fb8de1
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment