Move source code into internal directory to follow standard project layout.

https://github.com/golang-standards/project-layout
This commit is contained in:
Clement Michaud 2019-11-17 11:47:07 +01:00 committed by Clément Michaud
parent a06b69dd45
commit 3b2d733367
190 changed files with 188 additions and 323 deletions

View File

@ -8,7 +8,7 @@ import (
"os/exec"
"strings"
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
"github.com/spf13/cobra"
)
@ -19,6 +19,8 @@ type HostEntry struct {
}
var hostEntries = []HostEntry{
// For authelia backend
HostEntry{Domain: "authelia.example.com", IP: "192.168.240.50"},
// For common tests
HostEntry{Domain: "login.example.com", IP: "192.168.240.100"},
HostEntry{Domain: "admin.example.com", IP: "192.168.240.100"},

View File

@ -3,7 +3,7 @@ package main
import (
"os"
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

View File

@ -1,7 +1,7 @@
package main
import (
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

View File

@ -6,7 +6,7 @@ import (
"os"
"strings"
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

View File

@ -3,7 +3,7 @@ package main
import (
"fmt"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/spf13/cobra"
)

View File

@ -3,7 +3,7 @@ package main
import (
"os"
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

View File

@ -11,8 +11,8 @@ import (
"syscall"
"time"
"github.com/clems4ever/authelia/suites"
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/suites"
"github.com/clems4ever/authelia/internal/utils"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)
@ -137,6 +137,8 @@ func runSuiteSetupTeardown(command string, suite string) error {
s := suites.GlobalRegistry.Get(selectedSuite)
cmd := utils.CommandWithStdout("go", "run", "cmd/authelia-suites/main.go", command, selectedSuite)
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
cmd.Env = os.Environ()
return utils.RunCommandWithTimeout(cmd, s.SetUpTimeout)
}
@ -154,7 +156,10 @@ func setupSuite(suiteName string) error {
}()
if errSetup := runSuiteSetupTeardown("setup", suiteName); errSetup != nil || interrupted {
teardownSuite(suiteName)
err := teardownSuite(suiteName)
if err != nil {
log.Error(err)
}
return errSetup
}
@ -226,12 +231,14 @@ func runSuiteTests(suiteName string, withEnv bool) error {
if suite.TestTimeout > 0 {
timeout = fmt.Sprintf("%ds", int64(suite.TestTimeout/time.Second))
}
testCmdLine := fmt.Sprintf("go test ./suites -timeout %s -run '^(Test%sSuite)$'", timeout, suiteName)
testCmdLine := fmt.Sprintf("go test ./internal/suites -timeout %s -run '^(Test%sSuite)$'", timeout, suiteName)
log.Infof("Running tests of suite %s...", suiteName)
log.Debugf("Running tests with command: %s", testCmdLine)
cmd := utils.CommandWithStdout("bash", "-c", testCmdLine)
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
cmd.Env = os.Environ()
if headless {
cmd.Env = append(cmd.Env, "HEADLESS=y")
@ -240,7 +247,11 @@ func runSuiteTests(suiteName string, withEnv bool) error {
testErr := cmd.Run()
if withEnv {
teardownSuite(suiteName)
err := teardownSuite(suiteName)
if err != nil {
log.Error(err)
}
}
return testErr

View File

@ -1,7 +1,7 @@
package main
import (
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

View File

@ -1,7 +1,7 @@
package main
import (
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
)
// Docker a docker object

View File

@ -3,7 +3,7 @@
package main
import (
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/utils"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
)

View File

@ -4,8 +4,8 @@ import (
"encoding/base64"
"strings"
"github.com/clems4ever/authelia/configuration"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/configuration"
"github.com/clems4ever/authelia/internal/storage"
)
// TOTPSecretsV3 one entry of TOTP secrets in v3

View File

@ -8,8 +8,8 @@ import (
"path"
"time"
"github.com/clems4ever/authelia/models"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/models"
"github.com/clems4ever/authelia/internal/storage"
"github.com/spf13/cobra"
)

View File

@ -5,8 +5,8 @@ import (
"log"
"time"
"github.com/clems4ever/authelia/models"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/models"
"github.com/clems4ever/authelia/internal/storage"
"github.com/spf13/cobra"
"go.mongodb.org/mongo-driver/bson"
"go.mongodb.org/mongo-driver/mongo"

View File

@ -5,8 +5,8 @@ import (
"os"
"path/filepath"
"github.com/clems4ever/authelia/suites"
"github.com/clems4ever/authelia/utils"
"github.com/clems4ever/authelia/internal/suites"
"github.com/clems4ever/authelia/internal/utils"
"github.com/otiai10/copy"
log "github.com/sirupsen/logrus"
"github.com/spf13/cobra"
@ -18,7 +18,7 @@ var tmpDirectory = "/tmp/authelia/suites/"
var runningSuiteFile = ".suite"
func init() {
log.SetLevel(log.DebugLevel)
log.SetLevel(log.InfoLevel)
}
func main() {
@ -61,7 +61,7 @@ func setupSuite(cmd *cobra.Command, args []string) {
log.Fatal(err)
}
suiteResourcePath := cwd + "/suites/" + suiteName
suiteResourcePath := cwd + "/internal/suites/" + suiteName
exist, err := utils.FileExists(suiteResourcePath)

View File

@ -6,16 +6,16 @@ import (
"log"
"os"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/authorization"
"github.com/clems4ever/authelia/configuration"
"github.com/clems4ever/authelia/logging"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/notification"
"github.com/clems4ever/authelia/regulation"
"github.com/clems4ever/authelia/server"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/authorization"
"github.com/clems4ever/authelia/internal/configuration"
"github.com/clems4ever/authelia/internal/logging"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/notification"
"github.com/clems4ever/authelia/internal/regulation"
"github.com/clems4ever/authelia/internal/server"
"github.com/clems4ever/authelia/internal/session"
"github.com/clems4ever/authelia/internal/storage"
"github.com/sirupsen/logrus"
)

View File

@ -15,4 +15,5 @@ services:
- SUITE_PATH=${SUITE_PATH}
- ENVIRONMENT=dev
networks:
- authelianet
authelianet:
ipv4_address: 192.168.240.50

View File

@ -4,7 +4,7 @@ import (
"fmt"
"strings"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
"gopkg.in/ldap.v3"
)

View File

@ -6,7 +6,7 @@ import (
"regexp"
"strings"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
const userPrefix = "user:"

View File

@ -7,7 +7,7 @@ import (
"github.com/stretchr/testify/suite"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/stretchr/testify/assert"
)

View File

@ -5,8 +5,8 @@ import (
"gopkg.in/yaml.v2"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/configuration/validator"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/validator"
)
func check(e error) {

View File

@ -7,7 +7,7 @@ import (
)
func TestShouldParseConfigFile(t *testing.T) {
config, errors := Read("../test/resources/config.yml")
config, errors := Read("../../test/resources/config.yml")
assert.Len(t, errors, 0)

View File

@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/assert"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
type TestNestedStruct struct {

View File

@ -4,7 +4,7 @@ import (
"errors"
"strings"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
var ldapProtocolPrefix = "ldap://"

View File

@ -3,7 +3,7 @@ package validator
import (
"testing"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/suite"
)

View File

@ -3,7 +3,7 @@ package validator
import (
"fmt"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
var defaultPort = 8080

View File

@ -3,7 +3,7 @@ package validator
import (
"testing"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/stretchr/testify/assert"
)

View File

@ -3,7 +3,7 @@ package validator
import (
"errors"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
// ValidateSession validates and update session configuration.

View File

@ -3,7 +3,7 @@ package validator
import (
"testing"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/stretchr/testify/assert"
)

View File

@ -3,7 +3,7 @@ package validator
import (
"errors"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
// ValidateSQLStorage validates storage configuration.

View File

@ -1,7 +1,7 @@
package validator
import (
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
const defaultTOTPIssuer = "Authelia"

View File

@ -1,8 +1,8 @@
package handlers
import (
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/middlewares"
)
// SecondFactorAvailableMethodsGet retrieve available 2FA methods.

View File

@ -3,9 +3,9 @@ package handlers
import (
"testing"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/stretchr/testify/suite"
)

View File

@ -3,8 +3,8 @@ package handlers
import (
"fmt"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/middlewares"
)
// SecondFactorPreferencesGet get the user preferences regarding 2FA.

View File

@ -4,7 +4,7 @@ import (
"fmt"
"testing"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/golang/mock/gomock"
"github.com/sirupsen/logrus"

View File

@ -5,11 +5,11 @@ import (
"net/url"
"time"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/authorization"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/regulation"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/authorization"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/regulation"
"github.com/clems4ever/authelia/internal/session"
)
// FirstFactorPost is the handler performing the first factory.

View File

@ -4,9 +4,9 @@ import (
"fmt"
"testing"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/golang/mock/gomock"
"github.com/sirupsen/logrus"
"github.com/stretchr/testify/assert"

View File

@ -3,7 +3,7 @@ package handlers
import (
"fmt"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/middlewares"
)
// LogoutPost is the handler logging out the user attached to the given cookie.

View File

@ -4,7 +4,7 @@ import (
"strings"
"testing"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/stretchr/testify/assert"

View File

@ -3,8 +3,8 @@ package handlers
import (
"fmt"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/session"
"github.com/pquerna/otp/totp"
)

View File

@ -3,7 +3,7 @@ package handlers
import (
"fmt"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/tstranex/u2f"
)

View File

@ -4,7 +4,7 @@ import (
"crypto/elliptic"
"fmt"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/tstranex/u2f"
)

View File

@ -4,8 +4,8 @@ import (
"encoding/json"
"fmt"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/session"
)
func identityRetrieverFromStorage(ctx *middlewares.AutheliaCtx) (*session.Identity, error) {

View File

@ -3,7 +3,7 @@ package handlers
import (
"fmt"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/middlewares"
)
// ResetPasswordPost handler for resetting passwords

View File

@ -4,9 +4,9 @@ import (
"fmt"
"net/url"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/duo"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/duo"
"github.com/clems4ever/authelia/internal/middlewares"
)
// SecondFactorDuoPost handler for sending a push notification via duo api.

View File

@ -5,8 +5,8 @@ import (
"net/url"
"testing"
"github.com/clems4ever/authelia/duo"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/duo"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/suite"

View File

@ -4,8 +4,8 @@ import (
"fmt"
"net/url"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/pquerna/otp/totp"
)

View File

@ -4,9 +4,9 @@ import (
"crypto/elliptic"
"fmt"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/session"
"github.com/clems4ever/authelia/internal/storage"
"github.com/tstranex/u2f"
)

View File

@ -5,8 +5,8 @@ import (
"fmt"
"net/url"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/tstranex/u2f"
)

View File

@ -1,7 +1,7 @@
package handlers
import (
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/middlewares"
)
// StateGet is the handler serving the user state.

View File

@ -4,9 +4,9 @@ import (
"encoding/json"
"testing"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/suite"
)

View File

@ -8,9 +8,9 @@ import (
"strings"
"time"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/authorization"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/authorization"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/valyala/fasthttp"
)

View File

@ -6,10 +6,10 @@ import (
"net/url"
"testing"
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/authorization"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/authorization"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"
)

View File

@ -1,7 +1,7 @@
package handlers
import (
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/tstranex/u2f"
)

View File

@ -7,10 +7,10 @@ import (
"strings"
"github.com/asaskevich/govalidator"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/internal/session"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/logging"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/logging"
"github.com/valyala/fasthttp"
)

View File

@ -3,11 +3,11 @@ package middlewares_test
import (
"testing"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/internal/session"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"
"github.com/valyala/fasthttp"

View File

@ -6,7 +6,7 @@ import (
"fmt"
"time"
"github.com/clems4ever/authelia/templates"
"github.com/clems4ever/authelia/internal/templates"
jwt "github.com/dgrijalva/jwt-go"
)

View File

@ -5,9 +5,9 @@ import (
"testing"
"time"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/mocks"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/mocks"
"github.com/clems4ever/authelia/internal/session"
jwt "github.com/dgrijalva/jwt-go"
"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"

View File

@ -1,7 +1,7 @@
package middlewares
import (
"github.com/clems4ever/authelia/logging"
"github.com/clems4ever/authelia/internal/logging"
"github.com/valyala/fasthttp"
)

View File

@ -1,7 +1,7 @@
package middlewares
import (
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/internal/authentication"
)
// RequireFirstFactor check if user has enough permissions to execute the next handler.

View File

@ -1,13 +1,13 @@
package middlewares
import (
"github.com/clems4ever/authelia/authentication"
"github.com/clems4ever/authelia/authorization"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/notification"
"github.com/clems4ever/authelia/regulation"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/authentication"
"github.com/clems4ever/authelia/internal/authorization"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/notification"
"github.com/clems4ever/authelia/internal/regulation"
"github.com/clems4ever/authelia/internal/session"
"github.com/clems4ever/authelia/internal/storage"
jwt "github.com/dgrijalva/jwt-go"
"github.com/sirupsen/logrus"
"github.com/valyala/fasthttp"

View File

@ -5,14 +5,14 @@ import (
"fmt"
"testing"
"github.com/clems4ever/authelia/regulation"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/regulation"
"github.com/clems4ever/authelia/internal/storage"
"github.com/stretchr/testify/assert"
"github.com/clems4ever/authelia/authorization"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/middlewares"
"github.com/clems4ever/authelia/session"
"github.com/clems4ever/authelia/internal/authorization"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/middlewares"
"github.com/clems4ever/authelia/internal/session"
"github.com/golang/mock/gomock"
"github.com/sirupsen/logrus"
"github.com/sirupsen/logrus/hooks/test"

View File

@ -1,5 +1,5 @@
// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/clems4ever/authelia/duo (interfaces: API)
// Source: github.com/clems4ever/authelia/internal/duo (interfaces: API)
// Package mocks is a generated GoMock package.
package mocks
@ -8,7 +8,7 @@ import (
url "net/url"
reflect "reflect"
duo "github.com/clems4ever/authelia/duo"
duo "github.com/clems4ever/authelia/internal/duo"
gomock "github.com/golang/mock/gomock"
)

View File

@ -1,5 +1,5 @@
// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/clems4ever/authelia/notification (interfaces: Notifier)
// Source: github.com/clems4ever/authelia/internal/notification (interfaces: Notifier)
// Package mock_notification is a generated GoMock package.
package mocks

View File

@ -1,5 +1,5 @@
// Code generated by MockGen. DO NOT EDIT.
// Source: github.com/clems4ever/authelia/authentication (interfaces: UserProvider)
// Source: github.com/clems4ever/authelia/internal/authentication (interfaces: UserProvider)
// Package mocks is a generated GoMock package.
package mocks
@ -7,7 +7,7 @@ package mocks
import (
reflect "reflect"
authentication "github.com/clems4ever/authelia/authentication"
authentication "github.com/clems4ever/authelia/internal/authentication"
gomock "github.com/golang/mock/gomock"
)

View File

@ -5,7 +5,7 @@ import (
"io/ioutil"
"time"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
// FileNotifier a notifier to send emails to SMTP servers.

View File

@ -4,7 +4,7 @@ import (
"fmt"
"net/smtp"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/internal/configuration/schema"
)
// SMTPNotifier a notifier to send emails to SMTP servers.

View File

@ -4,9 +4,9 @@ import (
"fmt"
"time"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/models"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/models"
"github.com/clems4ever/authelia/internal/storage"
)
// NewRegulator create a regulator instance.

View File

@ -4,10 +4,10 @@ import (
"testing"
"time"
"github.com/clems4ever/authelia/configuration/schema"
"github.com/clems4ever/authelia/models"
"github.com/clems4ever/authelia/regulation"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/configuration/schema"
"github.com/clems4ever/authelia/internal/models"
"github.com/clems4ever/authelia/internal/regulation"
"github.com/clems4ever/authelia/internal/storage"
"github.com/golang/mock/gomock"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/suite"

View File

@ -3,7 +3,7 @@ package regulation
import (
"time"
"github.com/clems4ever/authelia/storage"
"github.com/clems4ever/authelia/internal/storage"
)
// Regulator an authentication regulator preventing attackers to brute force the service.

Some files were not shown because too many files have changed in this diff Show More