aboutsummaryrefslogtreecommitdiffstats
path: root/Godeps/_workspace/src/github.com/syndtr/goleveldb/leveldb/testutil/ginkgo.go
blob: 82f3d0e81113b7e85bc0f3b07d338333473882cc (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
package testutil

import (
    . "github.com/onsi/ginkgo"
    . "github.com/onsi/gomega"
)

func RunSuite(t GinkgoTestingT, name string) {
    RunDefer()

    SynchronizedBeforeSuite(func() []byte {
        RunDefer("setup")
        return nil
    }, func(data []byte) {})
    SynchronizedAfterSuite(func() {
        RunDefer("teardown")
    }, func() {})

    RegisterFailHandler(Fail)
    RunSpecs(t, name)
}