stub
Here are 253 public repositories matching this topic...
Describe the bug
When the (string) representations of the expected outcome and the actual outcome of e.g. assert.calledWith() are equal, the resulting error message is very confusing and hinting at a bug in the display logic. Instead of <red>actual</red> <green>expected</green> (with <color>...</color> my attempt at showing the expected terminal output color), it displays `actual
New Issue Checklist
- I have tried with the latest version of OHHTTPStubs
- I have read the README
- I have read the Using the right Swift Version of
OHHTTPStubsfor your project section - I have
At the moment MockIt supports
export const StatusCodes = {
OK: "200",
CREATED: "201",
NO_CONTENT: "204",
BAD_REQUEST: "400",
FORBIDDEN: "401",
INTERNAL_SERVER_ERROR: "500"
};
Might be worth adding some more? https://developer.mozilla.org/en-US/docs/Web/HTTP/Status
If anybody is up for the challenge :)?
I have a library that I generate all of my mocks into that is imported in my unit tests. When mocking a protocol, the generated mock object doesn't have an initializer declared. This means is uses the default initializer, which would be fine, except the default init() method is internal. I can get around this by importing my mock library @testable, but I'd suggest that protocol mocks for publi
From [this comment][3]:
I looked up the YARD docs for a
@paramtag and was surprised to see that the order should be: [@param name [Types] description][1]. I noticed that all of the Mocha YARD docs use@param [Types] name descriptionwhich seems odd. I trawled through the historical YARD documentation, CHANGELOG, and issues and [eventually discovered][2] that although the documented o
Looking at the source I can see we have functions such as deepEqual notNull, objectContaining which seem nice and are well named but aren't documented anywhere. Can you please document these and also document if custom verifications exist.
-
Updated
Apr 13, 2020 - Objective-C
-
Updated
Dec 16, 2018 - Assembly
I see things like Condition.get(String uri) which say that they accept a URI. But the examples show things like get("/demo"), which is not a URI at all --- it's a path. And there's no documentation about encoding at all.
Yes I know that Request.getRequestURI() really returns a path, but that's an old API and it was named badly to begin with. There are so many variations of things that are
-
Updated
Jul 8, 2020 - Objective-C
-
Updated
Sep 20, 2018 - Swift
Readme.md outdated
The following is still part of the readme.md:
Just mock and expects as usual and use chain to expects the chained methods. Finally call resolves or rejects (remember to require sinon-as-promised).
However (going there):
Sinon 2 added resolves and rejects methods and no longer requires this library.
-
Updated
Apr 4, 2020 - JavaScript
-
Updated
May 18, 2020 - PHP
-
Updated
Jul 1, 2020 - Swift
-
Updated
Apr 22, 2020 - Swift
-
Updated
May 15, 2020 - TypeScript
-
Updated
Apr 16, 2020 - C#
Improve this page
Add a description, image, and links to the stub topic page so that developers can more easily learn about it.
Add this topic to your repo
To associate your repository with the stub topic, visit your repo's landing page and select "manage topics."
When learning how to use mocker I came across this paragraph on this page: