edge/pkg/module/auth/testdata/auth_anonymous.js

9 lines
199 B
JavaScript
Raw Permalink Normal View History

2023-02-21 12:14:29 +01:00
function testAuth(ctx) {
var subject = auth.getSubject(ctx);
if (subject !== auth.ANONYMOUS) {
throw new Error("subject: expected '"+auth.ANONYMOUS+"', got '"+subject+"'");
}
}