- docs/services/jobs.md: declaring, registering and dispatching jobs, the summer_jobs record, progress, cancellation and workers - conga ExampleJob plus dispatch and status regions run by TestDocsDispatch on the package's Postgres harness (DocsApp in export_docs_test.go) - concept map links the queued jobs row; services/jobs is a required page
19 lines
522 B
Go
19 lines
522 B
Go
package conga
|
|
|
|
import (
|
|
"testing"
|
|
|
|
"git.golem15.com/golem15/summercms/modules/backpack"
|
|
"gorm.io/gorm"
|
|
)
|
|
|
|
// DocsApp returns an app and its GORM handle on a fresh migrated database
|
|
// of this package's Postgres harness, for the database-backed docs examples
|
|
// in example_test.go. It skips under -short and fails when the harness has
|
|
// no database, like the package's other database tests.
|
|
func DocsApp(t *testing.T) (*backpack.App, *gorm.DB) {
|
|
t.Helper()
|
|
db, dsn := migratedDB(t)
|
|
return testApp(t, db, dsn, nil)
|
|
}
|