Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_metric_to_fs_no_prepend(self):
in_ = "servers.s0123.foo.bar"
out = "servers/s0123/foo/bar.wsp"
assert metric_to_fs(in_) == out
def test_metric_to_fs_prepend(self):
in_ = "servers.s0123.foo.bar"
out = "/mnt/data/whisper/servers/s0123/foo/bar.wsp"
assert metric_to_fs(in_, prepend='/mnt/data/whisper') == out