大约有 15,480 项符合查询结果(耗时:0.0296秒) [XML]

https://stackoverflow.com/ques... 

JUnit test with dynamic number of tests

In our project I have several JUnit tests that e.g. take every file from a directory and run a test on it. If I implement a testEveryFileInDirectory method in the TestCase this shows up as only one test that may fail or succeed. But I am interested in the results on each individual file. How c...
https://stackoverflow.com/ques... 

Rails 3.1: Engine vs. Mountable App

...ns: [--full] # Generate a rails engine with bundled Rails application for testing [--mountable] # Generate mountable isolated application This gives the impression that you use --full to create an "engine" and --mountable to create something else called a "mountable application", when in fact they...
https://stackoverflow.com/ques... 

What is the purpose of mock objects?

I am new to unit testing, and I continously hear the words 'mock objects' thrown around a lot. In layman's terms, can someone explain what mock objects are, and what they are typically used for when writing unit tests? ...
https://stackoverflow.com/ques... 

Can unit testing be successfully added into an existing production project? If so, how and is it wor

I'm strongly considering adding unit testing to an existing project that is in production. It was started 18 months ago before I could really see any benefit of TDD (face palm) , so now it's a rather large solution with a number of projects and I haven't the foggiest idea where to start in adding u...
https://stackoverflow.com/ques... 

TransactionManagementError “You can't execute queries until the end of the 'atomic' block” while usi

...ransactions are handled in the newer versions of Django coupled with a unittest that intentionally triggers an exception. I had a unittest that checked to make sure a unique column constraint was enforced by purposefully triggering an IntegrityError exception: def test_constraint(self): try: ...
https://stackoverflow.com/ques... 

How to test an Android Library Project

...t AndroindLib) which contains only utility class (no activity). I tried to test it using Android JUnit, but it keeps complaining that can't find the AnroidLib.apk ...
https://stackoverflow.com/ques... 

NUnit Unit tests not showing in Test Explorer with Test Adapter installed

I've installed NUnit Test Adapter for VS2012 + 2013. When I first installed the Adapter tests were showing up, but they stopped showing up for some reason today. After building, rebuilding, cleaning, restarting, nothing shows up in Test Explorer. Why would this be happening? I'm using VS2013 Ult...
https://stackoverflow.com/ques... 

junit & java : testing non-public methods [duplicate]

JUnit will only test those methods in my class that are public. How do I do junit testing on the ones that are not (i.e., private, protected)? ...
https://stackoverflow.com/ques... 

TDD vs. Unit testing [closed]

My company is fairly new to unit testing our code. I've been reading about TDD and unit testing for some time and am convinced of their value. I've attempted to convince our team that TDD is worth the effort of learning and changing our mindsets on how we program but it is a struggle. Which bring...
https://stackoverflow.com/ques... 

How do you test private methods with NUnit?

I am wondering how to use NUnit correctly. First, I created a separate test project that uses my main project as reference. But in that case, I am not able to test private methods. My guess was that I need to include my test code into my main code?! - That doesn't seem to be the correct way to do it...