diff --git a/src/main.rs b/src/main.rs index 996653cc..e7dee931 100644 --- a/src/main.rs +++ b/src/main.rs @@ -19,12 +19,10 @@ // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. - use axum::routing::get; use axum::Router; - -mod home; -mod rs_err; +mod routes; +use crate::routes::home; #[tokio::main] async fn main() { diff --git a/src/home.rs b/src/routes/home.rs similarity index 98% rename from src/home.rs rename to src/routes/home.rs index c291bf3c..c574717d 100644 --- a/src/home.rs +++ b/src/routes/home.rs @@ -26,8 +26,7 @@ use axum::http::StatusCode; use axum::response::IntoResponse; use axum::Json; use tokio::fs; - -use crate::rs_err::RsErr; +use crate::routes::rs_err::RsErr; // @todo #9:25min Create unit tests for home.rs. // We need to create a few unit testes for home endpoints, diff --git a/src/routes/mod.rs b/src/routes/mod.rs new file mode 100644 index 00000000..6bab42b2 --- /dev/null +++ b/src/routes/mod.rs @@ -0,0 +1,2 @@ +pub mod home; +pub mod rs_err; diff --git a/src/rs_err.rs b/src/routes/rs_err.rs similarity index 100% rename from src/rs_err.rs rename to src/routes/rs_err.rs