mirror of
https://github.com/fosrl/pangolin.git
synced 2026-11-13 06:14:30 -06:00
Open
opened 2026-05-16 04:08:15 -05:00 by GiteaMirror
·
0 comments
No Branch/Tag Specified
main
dependabot/npm_and_yarn/npm-dependencies-adef1355ca
dependabot/go_modules/install/go-install-dependencies-1560069833
1-27
dependabot/npm_and_yarn/node-forge-1.4.3
feat/sync-idp-user-dir
l10n_dev
dev
website-checkout
dependabot/github_actions/github-actions-dependencies-6e53f9d9a5
dependabot/npm_and_yarn/node-forge-1.4.2
dependabot/github_actions/github-actions-dependencies-0c219a018e
extern-ws
1.26.0
1.26.0-rc.0
1.25.3
1.25.2
1.25.1
1.25.0
1.25.0-rc.0
1.24.0
1.24.0-rc.0
1.23.0
1.23.0-rc.0
1.22.2
1.22.1
1.22.0
1.22.0-rc.0
1.21.1
1.21.0
1.21.0-rc.0
1.20.0
1.20.0-rc.0
1.19.4
1.19.3
1.19.2
1.19.1
1.19.0
1.19.0-rc.1
1.19.0-rc.0
1.18.4
1.18.3
1.18.2
1.18.1
1.18.0
1.18.0-rc.0
1.17.1
1.17.0
1.17.0-rc.0
1.16.2
1.16.1
1.16.0
1.16.0-rc.0
1.15.4
1.15.3
1.15.2
1.15.1
1.15.0
1.15.0-rc.0
1.14.1
1.14.0
1.14.0-rc.0
1.13.1
1.13.0
1.13.0-rc.0
1.12.3
1.12.2
1.12.1
1.12.0
1.12.0-rc.0
1.11.1
1.11.0
1.10.3
1.10.2
1.10.1
1.10.0
1.9.4
1.9.3
1.9.2
1.9.1
1.9.0
1.8.0
1.7.3
1.7.2
1.7.1
1.7.0
1.6.2
1.6.1
1.6.0
1.5.1
1.5.0
1.4.0
1.3.2
1.3.1
1.3.0
1.2.0
1.1.0
1.0.1
1.0.0
1.0.0-beta.15
1.0.0-beta.14
1.0.0-beta.13
1.0.0-beta.12
1.0.0-beta.11
1.0.0-beta.10
1.0.0-beta.9
1.0.0-beta.8
1.0.0-beta.7
1.0.0-beta.6
1.0.0-beta.5
1.0.0-beta.4
1.0.0-beta.3
1.0.0-beta.2
1.0.0-beta.1
Labels
Clear labels
api
authentication
bug
config
dependencies
docker
documentation
enhancement
good first issue
help wanted
Improvement
Look Into
needs investigating
networking
new feature
non-critical bug
potential bug
pull-request
question
reverse proxy
Security
stale
ui
wontfix
Mirrored from GitHub Pull Request
No labels
pull-request
Milestone
No items
No Milestone
Projects
Clear projects
No projects
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/pangolin#16103
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/fosrl/pangolin/pull/2807
Author: @jbelke
Created: 4/7/2026
Status: 🔄 Open
Base:
dev← Head:test-api-full-suite📝 Commits (2)
da73b19test: add comprehensive API testing suite with 254 tests39f86edMerge branch 'fosrl:main' into test-api-full-suite📊 Changes
13 files changed (+3270 additions, -28 deletions)
View changed files
➕
.github/CODEOWNERS(+1 -0)📝
package-lock.json(+955 -26)📝
package.json(+6 -2)➕
test/bugs/identified-bugs.test.ts(+169 -0)➕
test/lib/ip.test.ts(+249 -0)➕
test/lib/passwordSchema.test.ts(+71 -0)➕
test/lib/sanitize.test.ts(+86 -0)➕
test/lib/utilities.test.ts(+86 -0)➕
test/lib/validators.test.ts(+279 -0)➕
test/schemas/auth.test.ts(+480 -0)➕
test/schemas/resource-org-site-role.test.ts(+488 -0)➕
test/schemas/user.test.ts(+361 -0)➕
vitest.config.ts(+39 -0)📄 Description
Community Contribution License Agreement
By creating this pull request, I grant the project maintainers an unlimited,
perpetual license to use, modify, and redistribute these contributions under any terms they
choose, including both the AGPLv3 and the Fossorial Commercial license terms. I
represent that I have the right to grant this license for all contributed content.
Description
Adds a comprehensive Vitest-based API testing suite with 254 tests across 9 test files covering schema validation, utility/library functions, and bug regression documentation.
What's included
Schema validation tests (Zod):
All schema tests validate
strictObjectrejection of unexpected fields, email lowercasing, boundary conditions, and required vs. optional field behavior.Library/utility tests:
validators— isValidCIDR, isValidIP, isValidDomain, isSecondLevelDomain, isValidUrlGlobPattern, isUrlValid, isTargetValid, validateHeadersip— cidrToRange, findNextAvailableCidr, isIpInCidr, doCidrsOverlap, parseEndpoint, formatEndpoint, portRangeStringSchema, parsePortRangeStringsanitize— null byte stripping, C0 control character removal, lone UTF-16 surrogate replacementpasswordSchema— all strength requirements (upper, lower, digit, special), min/max length boundariesnormalizePostAuthPath— open redirect prevention (//,:rejection), whitespace trimmingstoi— string-to-integer pass-through behaviorBug regression tests documenting 6 issues found during code review:
signup.ts:4emailnamed import fromzod— will break on Zod v4signup.ts:272SqliteErrorfor unique constraint — PostgreSQL duplicate signups get a 500 instead of "user already exists"resetPassword.ts:174ResetPasswordResponsebutdata: nullis set on successexternal.ts:970GET /idp/:idpIdroute registration (dead code)external.ts:1251-1284enable,request,disable) all usesignup:key prefix — rate limit bucket collisionexternal.ts:1235get-tokenrate limiter keys onreq.body.newtIdinstead ofreq.body.olmId(copy-paste from newt endpoint)These are documented as tests only; source fixes are intentionally deferred to a follow-up PR.
Infrastructure:
vitest.config.tswith v8 coverage provider and path aliasespackage.json: addedvitestdevDependency,test,test:watch,test:coveragescriptsDesign notes
@server/lib/config,@server/db, and@server/loggerat the module level sinceip.tsimports them at top-level even though the tested functions are pureHow to test?
Expected output:
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.