Package jsondata ::
Module Selftest
|
|
Module Selftest
source code
Test of basic features for the user by '--selftest'.
This module is used by 'jsondc' when the opverify_data_schemaardoced
basic functional checks by calling 'runselftest'.
The display of actions and results could be activated and raised by
multiple repetition of the '-v' option.
The following data and schema are applied:
-
jsondata/data.json + jsondata/schema.jsd
-
jsondata/datacheck.json + jsondata/datacheck.jsd
The performed process flow is:
-
load
-
validate
-
verify
By default either 'True' is returned, or in case of a failed test
and/or error condition an exception is raised.
Version:
0.2.12
Author:
Arno-Can Uestuensoez
Copyright:
Copyright (C) 2015-2016 Arno-Can Uestuensoez @Ingenieurbuero
Arno-Can Uestuensoez
License:
Artistic-License-2.0 + Forced-Fairplay-Constraints
|
|
|
|
|
|
|
|
|
|
|
|
|
jsonpointer_data_schema(appname)
Loads and verifies by using JSONPointer access 'data.json'. |
source code
|
|
|
jsonpointer_selftest_data(appname)
Loads and verifies by using JSONPointer access 'selftest.json'. |
source code
|
|
|
jsonpointer_selftest_data_schema(appname)
Loads and verifies by using JSONPointer access 'selftest.json'. |
source code
|
|
|
__uuid__ = ' 63b597d6-4ada-4880-9f99-f5e0961351fb '
|
|
_APPNAME = ' selftest '
|
|
_interactive = False
|
|
debug = False
|
|
_verbose = 0
|
|
__package__ = ' jsondata '
|
Performs the selftest returns True or False.
Executes some the basic runtime test cases for user verification.
Args:
appname: Name of the application. Changing this may break the
selftest.
default:=selftest
**kargs:
debug: Displays extended state data for developers.
Requires __debug__==True.
verbose: Extends the amount of the display of
processing data.
_verbose=#levels: Extends the amount of the display
of processing data by given number of levels
at once.
Returns:
Selftest object.
Raises:
bypassed subsystems
|
Loads and verifies the self test 'data.json'.
Therefore the result of the creation of JSONDataSerializer is compared
to the load by json.load().
|
Loads and verifies the self test 'selftest.json'.
Therefore the result of the creation of JSONDataSerializer is compared
to the load by json.load().
|
Loads and validates the self test 'data.json' and 'schema.jsd'.
Therefore the result of the creation of JSONDataSerializer is
performed with draft3 validation by jsonschema.validate().
|
Loads and validates the self test 'selftest.json' and
'selftest.jsd'.
Therefore the result of the creation of JSONDataSerializer is
performed with draft3 validation by jsonschema.validate().
|