Verifying the behavior of a software system against the expected behavior of that system.

learn more… | top users | synonyms

1
vote
0answers
42 views

Rules of thumb for test coverage [closed]

In general it makes sense to me to unit test everything besides glue classes which have no logic. They often catch mistakes and code smells even at the time of writing let alone protecting you from ...
1
vote
4answers
132 views

How and where to test if the JSON request objects generated by the front-end is valid

We have built a complex Angular application that sends multiple HTTP request to a REST service that is also built in house. Since both the frontend and the backend is being developed in parallel, ...
0
votes
2answers
80 views

How can I test code that verifies data sanity?

I have a large data structure that gets read in from XML. I've been given a large list of constraints that should hold between data members. For example, one of the constraints might look like ...
4
votes
2answers
75 views

Testing strategies for interpreter language parser

For a recent personal project, I started working on an interpreter for my own programming language. One of the ground rules I set for myself on this project is that I need to properly test as much of ...
0
votes
2answers
64 views

Possible to get path coverage but not condition coverage or other way around?

I was wondering if it was possible to get path coverage(executing all paths) but not condition coverage? Also, how about the other way, condition coverage, but not path coverage? A concrete example ...
3
votes
1answer
96 views

Is it unreasonable to implement a small domain specific scripting language?

At my new job, they are currently spending scores of labor hours that we don't have to do manual QA testing after every build. Nothing is automated at all. (We can only afford three developers, and ...
2
votes
2answers
134 views

How to enable my team to run integration tests against RedShift in parallel?

I am working with Docker to run my integration tests, it works pretty nice: I startup my docker containers (one with my server and one with the database) I run the IT using arquillian against these ...
-1
votes
1answer
69 views

Considering the testing software issues when designing software [closed]

When designing the software, must we consider how much this code could be testable? for example, if we used X technology/Class/Interface instead of Y, based on that X can be tested more easily than Y, ...
1
vote
0answers
49 views

How are JSON Web Token validators tested?

JSON Web Tokens (JWTs) are an open, industry standard method for representing claims securely between two parties. There are numerous implementations for JWT verification, but it looks like each ...
1
vote
2answers
377 views

“I'm done with my coding” from Agile perspective

Scenario: I'm working in an Agile environment. The dev environment has not been configured yet, and I'm told to code a piece of an application. I code the module and write appropriate unit tests for ...
1
vote
3answers
110 views

Are debug-build-only UI controls a bad practice?

Often, to simplify testing, I add UI controls that are only visible and enabled in debug build only. Or prepopulate mandatory input fields in debug build. Is this a bad practice? Assuming the release ...
2
votes
1answer
77 views

How to write tests for browser automation script

I have a couple of scripts (two in Python, one in Java) that use Selenium to drive a browser and download files from a website. I need to do some major refactoring before I do a major expansion, so I ...
3
votes
3answers
249 views

Unit Testing and 3rd party packages. Do I mock or not?

I'm just getting used to unit testing and on my new project I decided to adopt a TDD approach. My code below is to test the UserServices class which is responsible for creating a user, deleting a ...
5
votes
2answers
254 views

Report test failures “all at once”, or report them one by one

I am a sole developer working for an organisation that has no testing strategy. I am trying to integrate a crime system developed by a vendor with an external application I developed. The external ...
-2
votes
3answers
184 views

What is the most elemental workflow for TDD?

Gradle is such an interesting build tool that it prompted me to look at Spock and JUnit -- which I've never done before. What is the basic workflow with TDD? My approach has been to do frequent ...
-1
votes
1answer
106 views

What do developers do during testing phase of a waterfall life cycle? [closed]

If the testing phase is over 5 months long do the developers help the testers execute scripts? I don't know how it's done in a waterfall lifecycle where the phases are usually quite long.
4
votes
3answers
113 views

Unit Testing Module-Internal Functions

I'm writing a simple whitebox unit testing suite for a project I'm working on in C. The project is broken into modules (each has a .c file with an associated .h file), and all modules are compiled ...
0
votes
0answers
29 views

Test architecture for feature that spans several modules

We have several modules that handle various parts of an incoming message. Each module does some unrelated work on the message (for example, write to the DB; send to the client), and all modules are ...
2
votes
2answers
188 views

What is it called when you test a microservice by mocking the dependencies?

I've a RESTFul microservice written in Grails. This microservice has it's own DB. It also depends on two other microservices. A typical workflow of the service is: Receives a GET request from a ...
3
votes
4answers
339 views

Cleanup & Arrange practices during integration testing to avoid dirty databases

I'm coding tests in C# and I settled with this structure: try { // ========== // ARRANGE // ========== // Insert into the database all test data I'll need during the test // ====...
82
votes
9answers
9k views

What's the point of running unit tests on a CI server?

Why would you run unit tests on a CI server? Surely, by the time something gets committed to master, a developer has already run all the unit tests before and fixed any errors that might've occurred ...
0
votes
0answers
36 views

Testing Browser/OS combinations

We support IE9, IE10, IE11, Chrome and Firefox, and we support them on Win7, Win8, Win8, and Win10. If we tested every possible combination of browser and OS that would be 20 times through our script ...
0
votes
3answers
129 views

At what point in a projects life-cycle do you begin writing tests? [duplicate]

I'm not in the field, so I don't have any professional experience from projects following the TDD design. I am trying to adopt this pattern, but I'm confused as to when I start actually writing the ...
3
votes
3answers
142 views

How do you test a selenium framework?

I have a very large selenium test framework I use to test a web application. It it built around a page-object pattern. This week I fixed a bug in a low level piece of the framework, but it broke many ...
1
vote
0answers
32 views

How can I test for performance issues in a specific piece of code? [duplicate]

I've inherited a problem from a programmer that isn't with our group anymore - a piece of our application suffers from performance issues under a particular set of circumstances. I can replicate ...
1
vote
2answers
129 views

how to unit test constant that define an implementation detail?

How do I unit test a constant that define an implementation detail? and should I? For instance let's say I have the following class: class A { private Cache _cache; const int ...
3
votes
2answers
186 views

How unit test service method that use repository method

For service methods that call repository methods to interact with database how could I unit test these service methods? For example, public function updateSlideshow($data){ // do some logic ...
4
votes
0answers
132 views

Is there a simpler way to help testers push code to a testing branch?

I'm a amateur programmer, I'm not used to working with Git. It's my job to help test new code, for a while now this has included pulling the branch containing the issue, merging it with the main ...
4
votes
3answers
171 views

How narrow should my unit tests be?

Here's an example: I have a chat module in my app, and there's a ChatService class that is responsible for networking, and there's a ChatNotificationService helper class that is responsible for ...
6
votes
1answer
85 views

Strategies to maintain contract between mocks and APIs

Using a mock instead of hitting a 3rd party API like Postgres or Stripe can often be necessary when writing tests. A problem I've seen is when the API can unknowingly diverges from the data the mocks ...
6
votes
1answer
500 views

Unit testing an API client and wrappers

I've been going round in circles trying to figure out the best way to unit test an API client library I'm developing. The library has a Client class which basically has a 1:1 mapping with the API, and ...
2
votes
2answers
67 views

Acceptance testing with preloaded data or filling it on the go

We're figuring out whether we should write acceptance tests that revolves around preloaded data on a database file, or programmatically added needed data per test, or filling database while testing ...
5
votes
5answers
364 views

Can we add methods which is easier for assertion in test and which is only used in tests when TDD?

Here let me take a simple parking boy example. A parking boy can manage several parking lots, and when a car comes, he will park the car into some parking lot and can also help to un-park the car. ...
-1
votes
2answers
137 views

What technique can I use to test my code when code renders out an untestable(?) PDF document?

I have a need to test output of my code before I send the output for PDF rendering. Currently I have decided on a switch statement that does two different things depending on whether I am in ...
3
votes
1answer
123 views

What percentage of failed requests is “normal” [closed]

So I just launched my first "real" site that actually has a decent amount of interactions and whatnot. It's an ASP.net site with a SQL backend. We've served 130k requests in the last 12 hours but ...
6
votes
3answers
187 views

Stubbing Properties with private setters for tests

We have the object public class MyObject{ protected MyObject(){} public string Property1 {get;private set;} public string Property2 {get;private set;} public string Property3 {get;...
5
votes
6answers
633 views

Is it an overkill to write unit tests for a small code base? [duplicate]

I am the sole maintainer of a code base of about 2000 lines of code. It's not big, but over time the code became so unmaintainable my boss agreed to give me time to rewrite it from scratch. Since the ...
2
votes
0answers
98 views

What's the best way of testing client/server programs using Bamboo?

At my company, we've standardized on Bamboo for continuous integration. One of our products is a Server + a set of clients, and we want to test many different combinations. The way we do it is to have ...
10
votes
6answers
775 views

Why do we need both Priority and Severity?

I understand what they determine but is it really useful to assign those to issues found? I mean, it is either required to fixed quickly or not. I know how to set them, categorize them etc. I know ...
8
votes
1answer
1k views

Refactoring byzantine payment processing code on a limited budget [closed]

I've been working on a large Ruby on Rails application for several years. It was inherited in a poor state but most of the production bugs have been ironed out with time. There are some sections that ...
2
votes
4answers
138 views

Is it ok to use service locator for ubiquitously used dependencies? [closed]

We strictly adhere to inversion of control in our codebase, but that creates hellish constructors (yes, I know that means our classes aren't cohesive enough, this is a work in progress). The thing is, ...
5
votes
1answer
127 views

Strategies to increasing the maintainability of assertions in code [closed]

Background I am writing a compiler for a custom language for a school project and it is going really well for me. If I where to start all over from scratch I would have done many software ...
6
votes
1answer
141 views

Testing procedural code

TL;DR. Writing procedural code within a DB transaction. How can I improve design of the code so it's better testable? In my application I have a service object that perform multiple things within the ...
3
votes
3answers
187 views

Should defects be raised during sprints or just noted in the stories and assigned to developers?

I have heard that when testing stories developed in the current sprint, no issues are raised they are not completed (i.e. definition of done was not fulfilled) and that you should only raise issues ...
0
votes
1answer
111 views

How to write unit tests for an application that mostly performs “hard to test” actions? [duplicate]

In my company we develop medical data-acquisition systems. The main functions of each application are: Interface with data-sampling hardware; Save/load collected data to/from files on disk; Perform ...
48
votes
15answers
5k views

Almost every reported bug is a high-priority bug [closed]

I have noticed a pattern while working on several software projects: the big majority of the bugs reported had a high/very-high priority. I asked some colleagues about why this may be happening, and ...
1
vote
0answers
30 views

Do the terms “unit test” and “integration test” sometimes overlap or conflict? [duplicate]

By my understanding, a "unit test" is a test that makes assertions about the "smallest testable unit" - and an "integration test" is a test that depends on integration with an external system, e.g. ...
1
vote
1answer
94 views

Testing base-62 converter

I have a converter module which encodes non-negative numerics to base 62 strings and vice versa. I'm not very experienced with testing, and I got this so far: Encode Test for negative numbers Test ...
0
votes
1answer
55 views

Does testing the characteristics of a runtime have a generally accepted name? [closed]

I am working with PowerShell which doesn't seem to have an up-to-date language spec. This leaves me wondering about some edge cases. I've taken to testing my assumptions about how PowerShell's ...
0
votes
0answers
36 views

Is there value is putting test/build outputs under source control?

My colleagues insist on ploughing every bit of output data they can into subversion. I can't see the value in this practice and would much rather use a file system. The key offenders are build and ...