summaryrefslogtreecommitdiff
path: root/src/events/routes/test.rs
diff options
context:
space:
mode:
authorOwen Jacobson <owen@grimoire.ca>2024-09-27 20:18:50 -0400
committerOwen Jacobson <owen@grimoire.ca>2024-09-28 01:00:09 -0400
commit1458ff7be5d883444943090cb636e9343487d03e (patch)
treeadb410ce9245dc2a1562fc370f2398cab35e7507 /src/events/routes/test.rs
parenteff129bc1f29bcb1b2b9d10c6b49ab886edc83d6 (diff)
Send created events when channels are added.
Diffstat (limited to 'src/events/routes/test.rs')
-rw-r--r--src/events/routes/test.rs18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/events/routes/test.rs b/src/events/routes/test.rs
index f289225..55ada95 100644
--- a/src/events/routes/test.rs
+++ b/src/events/routes/test.rs
@@ -15,7 +15,7 @@ async fn includes_historical_message() {
let app = fixtures::scratch_app().await;
let sender = fixtures::login::create(&app).await;
- let channel = fixtures::channel::create(&app).await;
+ let channel = fixtures::channel::create(&app, &fixtures::now()).await;
let message = fixtures::message::send(&app, &sender, &channel, &fixtures::now()).await;
// Call the endpoint
@@ -42,7 +42,7 @@ async fn includes_live_message() {
// Set up the environment
let app = fixtures::scratch_app().await;
- let channel = fixtures::channel::create(&app).await;
+ let channel = fixtures::channel::create(&app, &fixtures::now()).await;
// Call the endpoint
@@ -75,8 +75,8 @@ async fn includes_multiple_channels() {
let sender = fixtures::login::create(&app).await;
let channels = [
- fixtures::channel::create(&app).await,
- fixtures::channel::create(&app).await,
+ fixtures::channel::create(&app, &fixtures::now()).await,
+ fixtures::channel::create(&app, &fixtures::now()).await,
];
let messages = stream::iter(channels)
@@ -117,7 +117,7 @@ async fn sequential_messages() {
// Set up the environment
let app = fixtures::scratch_app().await;
- let channel = fixtures::channel::create(&app).await;
+ let channel = fixtures::channel::create(&app, &fixtures::now()).await;
let sender = fixtures::login::create(&app).await;
let messages = vec![
@@ -156,7 +156,7 @@ async fn resumes_from() {
// Set up the environment
let app = fixtures::scratch_app().await;
- let channel = fixtures::channel::create(&app).await;
+ let channel = fixtures::channel::create(&app, &fixtures::now()).await;
let sender = fixtures::login::create(&app).await;
let initial_message = fixtures::message::send(&app, &sender, &channel, &fixtures::now()).await;
@@ -229,8 +229,8 @@ async fn serial_resume() {
let app = fixtures::scratch_app().await;
let sender = fixtures::login::create(&app).await;
- let channel_a = fixtures::channel::create(&app).await;
- let channel_b = fixtures::channel::create(&app).await;
+ let channel_a = fixtures::channel::create(&app, &fixtures::now()).await;
+ let channel_b = fixtures::channel::create(&app, &fixtures::now()).await;
// Call the endpoint
@@ -346,7 +346,7 @@ async fn removes_expired_messages() {
// Set up the environment
let app = fixtures::scratch_app().await;
let sender = fixtures::login::create(&app).await;
- let channel = fixtures::channel::create(&app).await;
+ let channel = fixtures::channel::create(&app, &fixtures::now()).await;
fixtures::message::send(&app, &sender, &channel, &fixtures::ancient()).await;
let message = fixtures::message::send(&app, &sender, &channel, &fixtures::now()).await;