Configuation meta data for an test
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(dependency_config_t), | public, | allocatable | :: | dependency(:) |
Dependency meta data for this executable |
||
type(string_t), | public, | allocatable | :: | link(:) |
Libraries to link against |
||
character(len=:), | public, | allocatable | :: | main |
Name of the source file declaring the main program |
||
character(len=:), | public, | allocatable | :: | name |
Name of the resulting executable |
||
character(len=:), | public, | allocatable | :: | source_dir |
Source directory for collecting the executable |
Dump dependency to toml table
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(srcfile_t), | intent(inout) | :: | self |
Instance of the serializable object |
||
type(toml_table), | intent(inout) | :: | table |
Data structure |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
Write serializable object to file
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(serializable_t), | intent(inout) | :: | self |
Instance of the dependency tree |
||
character(len=*), | intent(in) | :: | file |
File name |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
|
logical, | intent(in), | optional | :: | json |
Optional JSON format |
Write serializable object to a formatted Fortran unit
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(serializable_t), | intent(inout) | :: | self |
Instance of the dependency tree |
||
integer, | intent(in) | :: | unit |
Formatted unit |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
|
logical, | intent(in), | optional | :: | json |
Optional JSON format requested? |
Dump install config to toml table
Because dependencies are named, fallback if this has no name So, serialization will work regardless of size(self%dep) == self%ndep
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(executable_config_t), | intent(inout) | :: | self |
Instance of the serializable object |
||
type(toml_table), | intent(inout) | :: | table |
Data structure |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
Print information on this instance
Write information on instance
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(test_config_t), | intent(in) | :: | self |
Instance of the test configuration |
||
integer, | intent(in) | :: | unit |
Unit for IO |
||
integer, | intent(in), | optional | :: | verbosity |
Verbosity of the printout |
Read dependency from toml table (no checks made at this stage)
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(srcfile_t), | intent(inout) | :: | self |
Instance of the serializable object |
||
type(toml_table), | intent(inout) | :: | table |
Data structure |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
Read dependency tree from file
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(serializable_t), | intent(inout) | :: | self |
Instance of the dependency tree |
||
character(len=*), | intent(in) | :: | file |
File name |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
|
logical, | intent(in), | optional | :: | json |
Optional JSON format |
Read dependency tree from file init JSON interpreter Read object from TOML table
use default TOML parser
Read object from TOML table
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(serializable_t), | intent(inout) | :: | self |
Instance of the dependency tree |
||
integer, | intent(in) | :: | unit |
File name |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
|
logical, | intent(in), | optional | :: | json |
Optional JSON format |
Read install config from toml table (no checks made at this stage)
Read all dependencies
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(executable_config_t), | intent(inout) | :: | self |
Instance of the serializable object |
||
type(toml_table), | intent(inout) | :: | table |
Data structure |
||
type(error_t), | intent(out), | allocatable | :: | error |
Error handling |
Check that two source files are equal All checks passed!
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(srcfile_t), | intent(in) | :: | this | |||
class(serializable_t), | intent(in) | :: | that |
Serialization interface
All checks passed!
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(executable_config_t), | intent(in) | :: | this | |||
class(serializable_t), | intent(in) | :: | that |
Test load/write roundtrip
Test serialization of a serializable object Dump to scratch file Load from scratch file Check same
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(serializable_t), | intent(inout) | :: | self | |||
character(len=*), | intent(in) | :: | message | |||
type(error_t), | intent(out), | allocatable | :: | error |
type, extends(executable_config_t) :: test_config_t contains !> Print information on this instance procedure :: info end type test_config_t