Ejemplo n.º 1
0
func (t TestRunnerPlugin) OnRoutesLoaded(router *revel.Router) {
	router.Routes = append([]*revel.Route{
		revel.NewRoute("GET", "/@tests", "TestRunner.Index", ""),
		revel.NewRoute("GET", "/@tests.list", "TestRunner.List", ""),
		revel.NewRoute("GET", "/@tests/public/{<.*>filepath}", "Static.ServeModule", "testrunner,public"),
		revel.NewRoute("GET", "/@tests/{suite}/{test}", "TestRunner.Run", ""),
	}, router.Routes...)
	fmt.Println("Go to /@tests to run the tests.")
}
Ejemplo n.º 2
0
func (t TestRunnerPlugin) OnRoutesLoaded(router *revel.Router) {
	router.Routes = append([]*revel.Route{
		revel.NewRoute("GET", "/@tests", "TestRunner.Index"),
		revel.NewRoute("GET", "/@tests.list", "TestRunner.List"),
		revel.NewRoute("GET", "/@tests/public/", "staticDir:testrunner:public"),
		revel.NewRoute("GET", "/@tests/{suite}/{test}", "TestRunner.Run"),
	}, router.Routes...)
	fmt.Println("Go to /@tests to run the tests.")
}
Ejemplo n.º 3
0
func (t JobsPlugin) OnRoutesLoaded(router *revel.Router) {
	router.Routes = append([]*revel.Route{
		revel.NewRoute("GET", "/@jobs", "Jobs.Status", ""),
	}, router.Routes...)
	fmt.Println("Go to /@jobs to see job status.")
}