pub struct Config {Show 13 fields
pub name: String,
pub modules: Vec<ModuleConfig>,
pub homeserver: HomeserverConfig,
pub up: Option<UpScript>,
pub run: Option<Script>,
pub down: Option<DownScript>,
pub docker: DockerConfig,
pub users: Vec<User>,
pub synapse: SynapseVersion,
pub credentials: DockerCredentials,
pub directories: Directories,
pub workers: WorkersConfig,
pub autoclean_on_error: bool,
}Expand description
The contents of a mx-tester.yaml
Fields
name: StringA name for this test.
modules: Vec<ModuleConfig>Modules to install in Synapse.
homeserver: HomeserverConfigValues to pass through into the homeserver.yaml for this synapse.
up: Option<UpScript>A script to run at the end of the setup phase.
run: Option<Script>The testing script to run.
down: Option<DownScript>A script to run at the start of the teardown phase.
docker: DockerConfigConfiguration for the docker network.
users: Vec<User>Any users to register and make available
synapse: SynapseVersionThe version of Synapse to use
credentials: DockerCredentialsInformation for logging to a registry.
May be overridden from the command-line.
directories: DirectoriesDirectories to use for the test.
May be overridden from the command-line.
workers: WorkersConfigSpecify whether workers should be used.
May be overridden from the command-line.
autoclean_on_error: boolSpecify whether workers should be used.
May be overridden from the command-line.
Implementations
Create a builder for building Config.
On the builder, call .name(...), .modules(...)(optional), .homeserver(...)(optional), .up(...)(optional), .run(...)(optional), .down(...)(optional), .docker(...)(optional), .users(...)(optional), .synapse(...)(optional), .credentials(...)(optional), .directories(...)(optional), .workers(...)(optional), .autoclean_on_error(...)(optional) to set the values of the fields.
Finally, call .build() to create the instance of Config.
Create a map containing the environment variables that are common to all scripts.
Callers may add additional variables that are specific to a given script step.
Patch the homeserver.yaml at the given path (usually one that has been generated by synapse) with the properties in this struct (which will usually have been provided from mx-tester.yaml)
In multiple workers mode, also patch the worker files.
The directory in which we’re putting all data for this test.
Cleaned up upon test start.
The directory in which we’re putting everything related to synapse data for this test.
The directory in which Synapse may write data.
The directory in which we’re putting the configuration of workers for this test.
The directory in which we’re putting files that go to subdirectories of /etc in in the guest.
The name for the container we’re using to setup Synapse.
The name for the container we’re using to actually run Synapse.
Trait Implementations
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for Config
impl UnwindSafe for Config
Blanket Implementations
Mutably borrows from an owned value. Read more
pub fn vzip(self) -> V
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more