feat: serve the student app from the plugin
This commit is contained in:
@@ -115,6 +115,13 @@ func TestRoutes(t *testing.T) {
|
||||
if rt.PluginID != "jz.bm" {
|
||||
continue
|
||||
}
|
||||
if rt.Method+" "+rt.Pattern == "GET /{path...}" {
|
||||
// The student app, public by design; see static_test.go.
|
||||
if len(rt.Middleware) != 0 {
|
||||
t.Errorf("the student app has middleware %v", rt.Middleware)
|
||||
}
|
||||
continue
|
||||
}
|
||||
got = append(got, rt.Method+" "+rt.Pattern)
|
||||
if !slices.Contains(rt.Middleware, "jwt.auth") {
|
||||
t.Errorf("%s %s is not behind jwt.auth: %v", rt.Method, rt.Pattern, rt.Middleware)
|
||||
|
||||
Reference in New Issue
Block a user