All Projects → jaytaylor → mockery-example

jaytaylor / mockery-example

Licence: other
Advanced Example for mockery

Programming Languages

go
31211 projects - #10 most used programming language

Projects that are alternatives of or similar to mockery-example

php-mock-mockery
Mock non deterministic built-in PHP functions (e.g. time() or rand()) with Mockery.
Stars: ✭ 33 (+0%)
Mutual labels:  mockery
php-test-generator
Generate test cases for existing PHP files
Stars: ✭ 47 (+42.42%)
Mutual labels:  mockery
go-echo-boilerplate
The fastest way to build a restful API with golang and echo framework. Includes common required features for modern web applications. A boilerplate project with golang and Echo.
Stars: ✭ 53 (+60.61%)
Mutual labels:  mockery
Mockery
Mockery is a simple yet flexible PHP mock object framework for use in unit testing with PHPUnit, PHPSpec or any other testing framework. Its core goal is to offer a test double framework with a succinct API capable of clearly defining all possible object operations and interactions using a human readable Domain Specific Language (DSL).
Stars: ✭ 10,048 (+30348.48%)
Mutual labels:  mockery

Mockery-example

Example case for mockery issue #128 filed with the golang tool "mockery".

Get it

go get github.com/jaytaylor/mockery-example

Run it

go run main.go

Sample output:

$ go run main.go
common prefix: {
  Prefix: "2017-01-01"
}
content: {
  Key: "foo-object"
}

Run tests

go test -v ./...

Sample output:

$ go test -v ./...
=== RUN   TestS3Mock
--- PASS: TestS3Mock (0.00s)
    main_test.go:41: common prefix: {
          Prefix: "2017-01-01"
        }
PASS
ok      github.com/jaytaylor/mockery-example    0.222s
?       github.com/jaytaylor/mockery-example/mocks  [no test files]
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].