fix(session): make sure tunnel code is tested (#301)
* fix(session): make sure tunnel code is tested Part of https://github.com/ooni/probe/issues/985 * fix: add missing TunnelDir for correctness
This commit is contained in:
parent
8b92037ae3
commit
7172e750dd
4 changed files with 69 additions and 4 deletions
|
|
@ -20,7 +20,11 @@ func (s *Session) FetchPsiphonConfig(ctx context.Context) ([]byte, error) {
|
|||
// to tunnel.Start to fetch the Psiphon configuration.
|
||||
type sessionTunnelEarlySession struct{}
|
||||
|
||||
// errPsiphonNoEmbeddedConfig indicates that there is no
|
||||
// embedded psiphong config file in this binary.
|
||||
var errPsiphonNoEmbeddedConfig = errors.New("no embedded configuration file")
|
||||
|
||||
// FetchPsiphonConfig implements tunnel.Session.FetchPsiphonConfig.
|
||||
func (s *sessionTunnelEarlySession) FetchPsiphonConfig(ctx context.Context) ([]byte, error) {
|
||||
return nil, errors.New("no embedded configuration file")
|
||||
return nil, errPsiphonNoEmbeddedConfig
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue