-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix wrong test usage of AppSubURL
#29459
Conversation
Repo = "gogits/gogs" | ||
AppSubURL = AppURL + Repo + "/" | ||
AppURL = "http://localhost:3000/" | ||
FullURL = AppURL + "gogits/gogs/" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What does this mean?
Why "AppURL" is "http://localhost:3000/" but there is "gogits/gogs/" in FullURL?
- If the "gogits/gogs/" is for sub URL, then it should define AppSubURL to "/gogits/gogs"
- If the "gogits/gogs/" is for a repo like "user/repo", then it shouldn't be provided here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The repo info is in line 30+31. The localMetas
is global for the following tests, so the full url is build here too. Where would you put that code?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you. Maybe it could be called RepoFullURL
. I have no more question now.
The tests use an invalid `setting.AppSubURL`. The wrong behaviour disturbs other PRs like go-gitea#29222 and go-gitea#29427.
* giteaofficial/main: (23 commits) Fix wrong test usage of `AppSubURL` (go-gitea#29459) Improve contrast on blame timestamp, fix double border (go-gitea#29482) Fix/Improve `processWindowErrorEvent` (go-gitea#29407) Apply compact padding to small buttons with svg icons (go-gitea#29471) Fix counter display number incorrectly displayed on the page (go-gitea#29448) Fix incorrect user location link on profile page (go-gitea#29474) Fix workflow trigger event bugs (go-gitea#29467) Fix URL calculation in clone input box (go-gitea#29470) Remove jQuery from the "find file" page (go-gitea#29456) Move generate from module to service (go-gitea#29465) The job should always run when `if` is `always()` (go-gitea#29464) Recolor dark theme to blue shade (go-gitea#29283) Let ctx.FormOptionalBool() return optional.Option[bool] (go-gitea#29461) Implement actions badge svgs (go-gitea#28102) Fix missed return (go-gitea#29450) Use tailwind instead of `gt-[wh]-` helper classes (go-gitea#29423) Lock issues and pulls faster (go-gitea#29436) Allow to change primary email before account activation (go-gitea#29412) Update docs about `DEFAULT_ACTIONS_URL` (go-gitea#29442) Only use supported sort order for "explore/users" page (go-gitea#29430) ...
The tests use an invalid
setting.AppSubURL
. The wrong behaviour disturbs other PRs like #29222 and #29427.