mirror of
https://github.com/pomerium/pomerium.git
synced 2025-06-09 14:22:40 +02:00
pomerium-cli: add support for a custom browser command (#2617)
This commit is contained in:
parent
efffe57bf0
commit
a7442b1498
8 changed files with 58 additions and 17 deletions
|
@ -36,11 +36,8 @@ func TestAuthClient(t *testing.T) {
|
|||
_ = srv.Serve(li)
|
||||
}()
|
||||
|
||||
origOpenBrowser := openBrowser
|
||||
defer func() {
|
||||
openBrowser = origOpenBrowser
|
||||
}()
|
||||
openBrowser = func(input string) error {
|
||||
ac := New()
|
||||
ac.cfg.open = func(input string) error {
|
||||
u, err := url.Parse(input)
|
||||
if err != nil {
|
||||
return err
|
||||
|
@ -64,7 +61,6 @@ func TestAuthClient(t *testing.T) {
|
|||
return nil
|
||||
}
|
||||
|
||||
ac := New()
|
||||
rawJWT, err := ac.GetJWT(ctx, &url.URL{
|
||||
Scheme: "http",
|
||||
Host: li.Addr().String(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue