forgejo/tests/e2e/debugserver_test.go
oliverpool d9332cfff3 [v15.0/forgejo] tests: better factory with forgery package (#12540)
**Backport:** https://codeberg.org/forgejo/forgejo/pulls/11356

Conflicts:
- tests/integration/pull_review_test.go

Removed the modification, since the conflicting test added in #12015 is
not present in v15.0

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/11356
Reviewed-by: limiting-factor <limiting-factor@noreply.codeberg.org>
(cherry picked from commit 88ba174119)

### Release notes

- [ ] This change will be noticed by a Forgejo user or admin (feature, bug fix, performance, etc.). I suggest to include a release note for this change.
- [x] This change is not visible to a Forgejo user or admin (refactor, dependency upgrade, etc.). I think there is no need to add a release note for this change.

*The decision if the pull request will be shown in the release notes is up to the mergers / release team.*

The content of the `release-notes/<pull request number>.md` file will serve as the basis for the release notes. If the file does not exist, the title of the pull request will be used instead.

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/12540
Reviewed-by: limiting-factor <limiting-factor@noreply.codeberg.org>
2026-05-13 02:32:21 +02:00

32 lines
746 B
Go

// Copyright 2024 The Gitea Authors. All rights reserved.
// SPDX-License-Identifier: MIT
// This "test" is meant to be run with `make test-e2e-debugserver` and will just
// keep open a gitea instance in a test environment (with the data from
// `models/fixtures`) on port 3000. This is useful for debugging e2e tests, for
// example with the playwright vscode extension.
//nolint:forbidigo
package e2e
import (
"fmt"
"net/url"
"os"
"os/signal"
"syscall"
"testing"
"forgejo.org/modules/setting"
)
func TestDebugserver(t *testing.T) {
done := make(chan os.Signal, 1)
signal.Notify(done, syscall.SIGINT, syscall.SIGTERM)
onForgejoRun(t, func(*testing.T, *url.URL) {
DeclareGitRepos(t)
fmt.Println(setting.AppURL)
<-done
})
}