Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Sebastian Schrader
Kea
Commits
034e1d3b
Commit
034e1d3b
authored
May 06, 2013
by
JINMEI Tatuya
Browse files
[2823] clarify the purpose of mock auth statistics spec and data
parent
b308ba3b
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/bin/stats/tests/test_utils.py
View file @
034e1d3b
...
@@ -169,6 +169,10 @@ INIT_SPEC_STR = """\
...
@@ -169,6 +169,10 @@ INIT_SPEC_STR = """\
}
}
"""
"""
# Note: this is derived of the spec for the DNS authoritative server, but
# for the purpose of this test, it's completely irrelevant to DNS.
# Some statisittics specs do not make sense for practical sense but used
# just cover various types of statistics data (list, map/dict, etc).
AUTH_SPEC_STR
=
"""
\
AUTH_SPEC_STR
=
"""
\
{
{
"module_spec": {
"module_spec": {
...
@@ -448,7 +452,9 @@ class MyStatsHttpd(stats_httpd.StatsHttpd):
...
@@ -448,7 +452,9 @@ class MyStatsHttpd(stats_httpd.StatsHttpd):
# stats-httpd tests. For the purpose of these tests, the content of
# stats-httpd tests. For the purpose of these tests, the content of
# statistics data is not so important (they don't test whther the
# statistics data is not so important (they don't test whther the
# counter values are correct, etc), so hardcoding the common case
# counter values are correct, etc), so hardcoding the common case
# should suffice.
# should suffice. Note also that some of the statistics values and
# specs don't make sense in practice (see also comments on
# AUTH_SPEC_STR).
with
open
(
stats
.
SPECFILE_LOCATION
)
as
f
:
with
open
(
stats
.
SPECFILE_LOCATION
)
as
f
:
stat_spec_str
=
f
.
read
()
stat_spec_str
=
f
.
read
()
self
.
__default_spec_answer
=
{
self
.
__default_spec_answer
=
{
...
...
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