You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
27 lines
647 B
27 lines
647 B
package tests
|
|
|
|
import (
|
|
"testing"
|
|
"time"
|
|
// "github.com/stretchr/testify/require"
|
|
// "MY/webapp/data"
|
|
// sq "github.com/Masterminds/squirrel"
|
|
)
|
|
|
|
func TestTableListing(t *testing.T) {
|
|
z, cancel := Setup(t, 2 * time.Second);
|
|
defer cancel();
|
|
|
|
// confirm redirect if not logged in
|
|
z.GoTo("/admin/table/", `[data-testid="index-page"]`)
|
|
|
|
// now log in and go to admin
|
|
|
|
z.GoTo("/login/", `[data-testid="login-index-page"]`)
|
|
z.TypeIn(`#username`, `admin`)
|
|
z.TypeIn(`#password`, `testing123`)
|
|
z.ClickOn(`#login-submit`)
|
|
z.WaitFor(`[data-testid="index-page"]`)
|
|
|
|
z.GoTo("/admin/table/", `[data-testid="admin-table--page"]`)
|
|
}
|
|
|