View Source Phy.File behaviour (phy v0.1.1)

This module is responsible for all file operations.

Each function has a second implementation that is used for testing. This second implementation accepts a File mock module that implements the file-system related function that is being tested.

Summary

Callbacks

@callback exists?(path :: String.t()) :: boolean()
@callback exists?(path :: String.t(), any()) :: boolean()
@callback mkdir_p(path :: String.t()) :: :ok
@callback mkdir_p(path :: String.t(), any()) :: :ok
@callback write!(String.t(), String.t()) :: :ok
@callback write!(String.t(), String.t(), any()) :: :ok

Functions

Link to this function

exists?(path, file \\ File)

View Source
Link to this function

mkdir_p(path, file \\ File)

View Source
Link to this function

write!(path, content, file \\ File)

View Source