summaryrefslogtreecommitdiff
path: root/lib9p/tests/test_server/main.c
diff options
context:
space:
mode:
authorLuke T. Shumaker <lukeshu@lukeshu.com>2025-04-16 09:05:28 -0600
committerLuke T. Shumaker <lukeshu@lukeshu.com>2025-04-16 09:05:28 -0600
commit29ad1efc7c6de44a965db9f181165b72a9ef8ff1 (patch)
treee13794366a09d0480253076d458b413faa5680a5 /lib9p/tests/test_server/main.c
parent802ed1e3cd0252cafd1be2aada0addf4d3f7eb2e (diff)
parenta5061fa634af1e7011182e1c115151dd96af8393 (diff)
Merge branch 'lukeshu/9p-fix-flush'
Diffstat (limited to 'lib9p/tests/test_server/main.c')
-rw-r--r--lib9p/tests/test_server/main.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib9p/tests/test_server/main.c b/lib9p/tests/test_server/main.c
index 0705747..d7819eb 100644
--- a/lib9p/tests/test_server/main.c
+++ b/lib9p/tests/test_server/main.c
@@ -19,8 +19,8 @@
#include <util9p/static.h>
#include "static.h"
+#include "fs_flush.h"
#include "fs_shutdown.h"
-#include "fs_slowread.h"
#include "fs_whoami.h"
/* configuration **************************************************************/
@@ -76,11 +76,12 @@ struct lib9p_srv_file root =
API_FILE(5, "shutdown", shutdown,
.listeners = globals.listeners,
.nlisteners = LM_ARRAY_LEN(globals.listeners)),
- API_FILE(6, "slowread", slowread,
- .flushable = false),
- API_FILE(7, "slowread-flushable", slowread,
- .flushable = true),
API_FILE(8, "whoami", whoami),
+ API_FILE(9, "flush-read", flush, .flush_cnt=1, .flush_behavior=FLUSH_READ),
+ API_FILE(10, "flush-error", flush, .flush_cnt=1, .flush_behavior=FLUSH_ERROR),
+ API_FILE(11, "flush-silent", flush, .flush_cnt=1, .flush_behavior=FLUSH_SILENT),
+ API_FILE(12, "flush-slowsilent", flush, .flush_cnt=2, .flush_behavior=FLUSH_SILENT),
+ API_FILE(13, "flush-slowread", flush, .flush_cnt=0, .flush_behavior=FLUSH_READ),
);
static lo_interface lib9p_srv_file get_root(struct lib9p_srv_ctx *LM_UNUSED(ctx), struct lib9p_s LM_UNUSED(treename)) {