testing

Testing fault tolerant code

I’m currently working on a server application were we have agreed to try and maintain a certain level of service. The level of service we want to guaranty is: if a request is accepted by the server and the server sends on an acknowledgement to the client we want to guaranty that the request will happen, even if the server crashes. As req...

Test, if object was deleted

Look to the following code, please: class Node { private: double x, y; public: Node (double xx, double yy): x(xx), y(yy){} }; int main() { Node *n1 = new Node(1,1); Node *n2 = n1; delete n2; n2 = NULL; if (n1 != NULL) //Bad test { delete n1; //throw an exception } } There are two pointers n1, n2 pointe...

How to create a web service load test using Visual Studio 2010?

Is there a way to test a Web Service using VS2010 like it's used to test a web site? For a web site I can create a set of WebTestRequest objects that emulate the loading and the parsing of a web page from the test and then, implementing the GetRequestEnumerator I can yield results to the load test so that the execution time and payload ...

MvcContrib Test Helper problem

I am using MVC2 with MvcContrib HelpTester. I have problem with testing Controllers which are in Areas. Here is my Test class : [TestFixture] public class RouteTests { [TestFixtureSetUp] public void Setup() { RouteTable.Routes.Clear(); MvcApplication.RegisterRoutes(RouteTable.R...

Where can I find project repositories with continuous testing?

I am interested in studying some test logs from different projects, in order to build and test an application for school. I need to analyze the parts of the code which are tested, the bugs which appeared in those parts and eventually how they were resolved. But for this I need some repositories from different (open source) projects. Ca...

Unit Testing and motivation to do so

I'm currently Unit Testing an application that isn't build to support unit testing very well, lot's of dependencies, refactoring and the developers who build the application didn't think of unit testing when they started developing. My job is to do research for unit testing, unit test the application and bring unit testing into the organ...

Code Coverage tool for BlackBerry

I'm looking for a code coverage tool that I can use with a BlackBerry application. I'm using J2ME-Unit for Unit Testing and I want to see how much of my code is being covered by my tests. I've tried using Cobertura for J2ME but after days of wrestling with it I failed to get any results from it. (I believe that the instrumentation is un...

How to use EMMA code coverage in android.

Hi all, Im new to EMMA, i dont know how to use this for android system. Can anyone please give a sample for using this with android. Thanks a lot. ...

What's the best practice to setup testing for ASP.Net MVC? What to use/process/etc?

hi there, i'm trying to learn how to properly setup testing for an ASP.Net MVC. and from what i've been reading here and there thus far, the definition of legacy code kind of piques my interests, where it mentions that legacy codes are any codes without unit tests. so i did my project in a hurry not having the time to properly setup un...

Junit run not picking file src/test/resources. For file required by some dependency jar

Hi, I m facing a issue where test/resource is not picked,but instead jar's main/resource is picked Scenario is like : Myproject src/test/resources--- have config.xml w which should be needed by abc.jar which is a dependecy in Myproject. When running test case for Myproject its loading config.xml of abc.jar instead of Myproject test/res...

TF30063 Error in Test Professional 2010 / Microsoft Test Manager

I am receiving the following error when attempting to run my tests: You cannot run the selected tests TF30063: You are not authorized to access http://localhost:9899/tfs/DefaultCollection Everything else works fine, can create issues, bugs, i can plan tests but when i run it.. i get this everytime ...

Test FTP locally with WAMP 2.0?

I have WAMP 2.0 installed and am working on a content management system using PHP and MySQL. Is it possible to use the PHP FTP functions on my local machine, so I can test them? Thanks! Mike ...

How do you use Selenium to execute javascript within a frame?

I have a page (index.html) which has a frame: <html> <body> <iframe src="otherPage.html" /> </body> </html> And the otherPage.html has the contents: <html> <head><link src="jquery-min.js" type="text/javascript" /></head> <body><div id="main">Contents</div></body> </html> I am attempting to use the following selenium code on index.h...

Automate Testing on future only items business rules

I currently have a business object with a validation business rule, which is it can only be created for the future, tomorrow onwards, and I cannot create new items for today. I have a process, which runs the non-future business objects through some steps.. Because I have to set things up today, and test tomorrow, and when it fails, I c...

How much of Grails GORM to test?

Is there a "best practice" or defacto standard with how much of the GORM functionality one should test in the unit/functional tests? My take is that one should probably do most of the domain testing as functional tests so that you get the full grails environment. But what do you test? Inserts, updates, deletes? Do you test constraints e...

Testing out of space conditions in iPhone

What's the easiest way to simulate or create out of space conditions in iPhone, both on the simulator and on an actual device? I would like to test the code that handles such situations. ...

Recommendations for keeping a build server updated

As a guy who frequently switches between QA, build and operations, I keep running into the issue of what to do about operating system updates on the build server. The dichotomy is the same on Windows, Linux, MacOS or any other o/s that can update itself via the internet: The QA team wants to keep the build server exactly as it is from...

Using Assert to compare two objects

Hi everyone, Writing test cases for my project, one test I need is to test deletion. This may not exactly be the right way to go about it, but I've stumbled upon something which isn't making sense to me. Code is like this: [Test] private void DeleteFruit() { BuildTestData(); var f1 = new Fruit("Banana",1,1.5); var f2 = new...

httpwatch automation code doesn't work in IE6

Controller con = new Controller(); Plugin plugin = null; try { plugin = con.New(); } catch (Exception ex) { Console.WriteLine(ex.Message); } my code running fine in IE8. But same code does not work in a different machine with IE6. I would request ...

Using Moq callbacks correctly according to AAA

I've created a unit test that tests interactions on my ViewModel class in a Silverlight application. To be able to do this test, I'm mocking the service interface, injected to the ViewModel. I'm using Moq framework to do the mocking. to be able to verify bounded object in the ViewModel is converted properly, I've used a callback: [T...