You are not logged in. Your edit will be placed in a queue until it is peer reviewed.
We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.
- 4Don't forget about regression tests to cover discovered and fixed bugs to prevent their reintroduction into a system during future maintenance.RBerteig– RBerteig2011-04-06 07:15:17 +00:00Commented Apr 6, 2011 at 7:15
- 6I would not insist on the definition even if I agree with it. Some code might have acceptable dependencies like a StringFormatter and it still considered by most a unit test.johnlemon– johnlemon2013-09-25 07:06:00 +00:00Commented Sep 25, 2013 at 7:06
- 6danip: clear definitions are important, and I would insist on them. But it's also important to realize that those definitions are a target. They're worth aiming for, but you don't always need a bullseye. Unit tests will often have dependencies on lower-level libraries.Jeffrey Faust– Jeffrey Faust2013-12-03 13:54:51 +00:00Commented Dec 3, 2013 at 13:54
- 2Also it is important to understand the concept of facade tests, that don't test how components fit together (like integration tests) but test a single component in isolation. (ie. an object graph)Ricardo Rodrigues– Ricardo Rodrigues2014-09-24 16:10:07 +00:00Commented Sep 24, 2014 at 16:10
- 2its not only about being faster but rather about being extremely tedious or unmanageable, imagine, if you don't do, your execution tree of mocking might be exponentially growing. Imagine you mock 10 dependencies in your unit if you push mocking further let's say 1 of that 10 dependencies is used at many places and it has 20 of its own dependencies, so you have to mock + 20 other dependencies, potentially duplicately at many places. at the final- api point you have to mock - eg database, so that you don't have to reset it and it's faster as you toldFrantisek Hallo– Frantisek Hallo2019-10-06 22:49:23 +00:00Commented Oct 6, 2019 at 22:49
Add a comment |
How to Edit
- Correct minor typos or mistakes
- Clarify meaning without changing it
- Add related resources or links
- Always respect the author’s intent
- Don’t use edits to reply to the author
How to Format
- create code fences with backticks ` or tildes ~ ```
like so
``` - add language identifier to highlight code ```python
def function(foo):
print(foo)
``` - put returns between paragraphs
- for linebreak add 2 spaces at end
- _italic_ or **bold**
- indent code by 4 spaces
- backtick escapes
`like _so_` - quote by placing > at start of line
- to make links (use https whenever possible) <https://example.com>[example](https://example.com)<a href="https://example.com">example</a>
How to Tag
A tag is a keyword or label that categorizes your question with other, similar questions. Choose one or more (up to 5) tags that will help answerers to find and interpret your question.
- complete the sentence: my question is about...
- use tags that describe things or concepts that are essential, not incidental to your question
- favor using existing popular tags
- read the descriptions that appear below the tag
If your question is primarily about a topic for which you can't find a tag:
- combine multiple words into single-words with hyphens (e.g. design-patterns), up to a maximum of 35 characters
- creating new tags is a privilege; if you can't yet create a tag you need, then post this question without it, then ask the community to create it for you