3 Commits (master)

Author SHA1 Message Date
veypi f7c4f1ee86 test: improve test stability and documentation
- Add 'clean_run.sh' script to reset database and restart server for clean test environment
    - Update 'README.md' with detailed troubleshooting guide and pitfalls
    - Add '04_org_load_middleware.sh' to test LoadOrg middleware functionality
    - Update 'run_all.sh' to include new middleware test
    - Fix BASE_URL handling in 'lib.sh' and test scripts to support custom environments
    - Update '02_resource_perm.sh' to fix admin permission checks
    - Remove debug logging from 'auth.go'
1 week ago
veypi 1f380587a9 refactor(tests): Restructure test scripts with better coverage
- Add 00_none_auth.sh for unauthenticated access testing
    - Replace 01_basic_auth.sh with 01_setup_users.sh for comprehensive user setup
    - Replace 02_user_permission.sh with 02_resource_perm.sh for cross-user permission tests
    - Update lib.sh to handle non-numeric code fields in response
    - Update README.md with new test structure and usage instructions
    - Update run_all.sh with new test sequence
1 week ago
veypi d7ee1a1f4e test: 添加集成测试脚本
新增 scripts/tests/ 目录,包含权限测试脚本:
- lib.sh: 公共函数库(API请求、用户/组织操作封装)
- 01_basic_auth.sh: 基础认证测试(注册、登录、改密、刷新token)
- 02_user_permission.sh: 用户权限测试(admin/user角色、信息修改权限)
- 03_org_permission.sh: 组织权限测试(创建组织、成员权限、修改权限)
- run_all.sh: 运行所有测试
- README.md: 测试说明文档

删除旧的 test.sh
1 week ago