testing

Where could I find some code examples about Integration Testing

I have methods that interact with DB and external files. I need to write integration tests, however I am not sure how to. Do you know where I can find some source codes about integration testing with Database or External File? If you write a test method that tests a production method in which there are calls to other methods, is this a...

Tips for balancing between Dogfood and QA?

Most developers are aware of idea of eating one's own dog food, but at the same time its mathematically proven that its cheaper to have QA staff (or Testers) do QA than having developers do QA. Now of course there is no point in being an extremist in either direction, but I've noticed that depending on the project and developer (or QA s...

Parsing a Flex Application Object Hierarchy Using FunFX

I'm attempting to test a Flex application in which Objects do not have static IDs. I'd like to use FunFX for automation, since it can easily be kicked off from a Linux shell. This said, FunFX doesn't appear to contain functions which allow users to access children via their parent objects (e.g. parent.get_child_at(<index>) or parent.ch...

Testing/Debugging website running on iis 6.0 and 7.0 with an xp development environment?

Considering iis 6.0 and above can't run on xp what options have i available? Remote debugging (using a win 2k3 host) i'm aware of but i might not have the facilities available very easily ...

What is the "right" way to test the output of Java methods?

In Python, I often have tests which look something like this: tests = [ (2, 4), (3, 9), (10, 100), ] for (input, expected_output) in tests: assert f(input) == expected_output What is the "right" way to write tests like this (where a set of test cases is specified, then a loop runs each of them) in Java with JUnit? Tha...

Switching test::unit with rspec under rails

Kinda odd question here: when you go with rpsec instead of test::unit on rails, what do you do with the test dir? Keep it (for any compatibility issues maybe?) or remove it? ...

Can you or do you write Junit style unit tests without expliciting using 'assertEquals', exceptions fail test

I noticed some unit tests, like in the spring framework where you setup the object and the test but don't explicitly use the assert methods. Essentially, you have an exception or not. Is this unit testing? Is this something to avoid? For example, here are some tests from the Spring framework. No assert clauses, just a test. public v...

(Mis)Understanding Smalltalk and TDD

I'm trying to learn Smalltalk by doing, so I'm getting a grip on the syntax and style by buiding a simple "Matrix" class. First of all, I'd be grateful if linked to a good Smalltak tutorial (although this is totally optional), preferably one that doesn't involve using the GUIs (I'd rather type my .sts than fish around the hierarchy expl...

WatiN, VBScript

I am using WatiN for my web tests. In one of my web pages, I have a VBScript function which opens a dialogbox. I am unable to access it using WatiN. I tried using WatiNTestRecorder; it was unsuccessful. I tried this also: http://blogs.dovetailsoftware.com/blogs/kmiller/archive/2008/07/16/scenario-testing-with-watin.aspx, unsuccessf...

JUnit: how to avoid "no runnable methods" in test utils classes

I have switched to JUnit4.4 from JUnit3.8. I run my tests using ant, all my tests run successfully but test utility classes fail with "No runnable methods" error. The pattern I am using is to include all classes with name *Test* under test folder. I understand that the runner can't find any method annotated with @Test attribute. But the...

Where can I buy the QTP tool?

I am downloading the trial version of QTP but I cannot find the link to buy the QTP tool. Where can I buy QTP? ...

JDBC Thin Driver: Invalid Packet Lenght [sic]

I have encountered a strange "Invalid Packet Lenght" (that is how the error is spelled) error when I run an automated bulk test on some of my Java code and I hope that someone has either encountered this error before or can point me in the right direction. I do not encounter this error when testing my code via JUnit unit tests or from...

JUnit assertion extensions

I'm often creating custom assertion methods for my JUnit tests. eg: public void assertArrays(String[] actual, String[] expected) I was wondering if there were any decent third party libraries that can provide a wider range of assertions than what comes by default in JUnit. Am using JUnit 4. ...

Open source tools for Windows Application

Do you know any open source tools for testing windows application?? ...

Standard Documents or Software to write Test Scenarios (or functional tests)

Are there standard documents around to write Test Scenarios (or functional tests/ acceptance tests)? Maybe software to input the scenarios and check them if passed... Now we use Word or Excel to do this but having a system to track the results of previous test scenarios would be usefull. thx, Lieven Cardoen ps: The tests are pure func...

Doctest for dynamically created objects.

What is the best way to test code like this (the one below obviously fails while object is created in different block every time): def get_session(db_name, verbose, test): """Returns current DB session from SQLAlchemy pool. >>> get_session('Mmusc20090126', False, True) <sqlalchemy.orm.session.Session object at 0xfb5ff0> """ if test: ...

WatiN in Visual Studio 2008 - second test method fails

When trying to run a very simple WatiN 2.0 (CTP3) test in Visual Studio 2008 I found that the first one always executes fine. The second test method seem to break something in the IE object producing the following exception: Test method testProject.WatinTest.testTwo threw exception: System.Runtime.InteropServices.InvalidComObj...

Which version control programs can enforce running & passing of tests before integration of changes?

At my work we currently use Aegis version control/SCM. The way we have it configured, we have a bunch of tests, and it forces the following things to be true before a change can be integrated: The full set of tests must have been run. All tests must have passed. With test-driven development (TDD) these seem like sensible requirements...

How to handle cookies when testing with Webrat?

Hi! I'm writing Cucumber tests for a Sinatra based application using Webrat. For some tests I need to implement a scenario like Given I am logged in as admin When I am visiting "/" Then I should see "Settings" I define steps like this: Given /^I am logged in as "(.+)"$/ do |user| visit "/login" fill_in "login", :with => user...

internet explorer 6 testing

Hi, Is there any way to test a website in IE6 on a computer that already has firefox and IE7 installed, without either: Using VM-ware Uninstalling IE7 and installing IE6 (if that's even possible) Cheers, Don Duplicate Possible to degrade from IE7 to IE6 for debuggin purposes? ...