salt.thorium.file module

Writes matches to disk to verify activity, helpful when testing

Normally this is used by giving the name of the file (without a path) that the data will be saved to. If for instance you use foo as the name:

Then the file will be saved to:

You may also provide an absolute path for the file to be saved to:


Files will be saved in JSON format. However, JSON does not support set()``s. If you are saving a register entry that contains a ``set(), then it will fail to save to JSON format. However, you may pass data through a filter which makes it JSON compliant:

    filter: True

Be warned that if you do this, then the file will be saved, but not in a format that can be re-imported into Python., filter=False)

Save the register to <salt cachedir>/thorium/saves/<name>, or to an absolute path.