feat: faker cmd for fake test entities

This commit is contained in:
əlemi 2024-03-16 05:46:14 +01:00
parent 85c9b363f6
commit 52f7ee0990
Signed by: alemi
GPG key ID: A4895B84D311642C

View file

@ -30,6 +30,9 @@ enum CliCommand {
/// apply database migrations
Migrate,
/// generate fake user, note and activity
Faker,
}
#[tokio::main]
@ -55,6 +58,9 @@ async fn main() {
CliCommand::Migrate => migrations::Migrator::up(&db, None)
.await.expect("error applying migrations"),
CliCommand::Faker => model::faker(&db)
.await.expect("error creating fake entities"),
}
}