Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?

Introduction

A simple portal for tracking testing reports, bugs found and then mapping all this way back to features and releases. However JIRA and other such project management tools provide the features that are mentioned in this document but still this solution can come in handy for those who don't want an outside tool rather a quick dirty solution.
Note this is for a general solution overview and focusses more on data modelling. Any installation and setup related findings is homework for reader :)

What all is compassed in testing ?

  1. Testing Report
  2. Bugs
  3. Releases
  4. Features
  5. Test cases
  6. Environment

What all do you need to see in a testing dashboard ?

  1. Timeline of all testing that has happened till date
  2. Individual testing report
  3. Test cases, which cases map to which feature(s)
  4. Testing cycles for a specific release
  5. Bugs introduced in a release, mapped to which feature(s)

The portal solution involves :

  1. Mongodb
  2. Mongodb Compass - mongodb dashboard tool
  3. Elasticsearch
  4. Kibana - elastic search dashboard tool

How will it work

Managing Testing Metadata in Mongodb

We use mongodb as database/storage for all the testing related metadata we have i.e. bugs, test cases, release versions, testing cycles. Exact modelling of data will come in later section. To manage mongodb as well as to have an interface to enter metadata/information in mongodb, we can use Mongodb Compass (a solution by mongodb itself).

Making sense of data

Kibana has excellent dashboard functionality, it provides various chart types for every possible reporting type that one may need. So to facilitate Kibana we integrate ElasticSearch with Mongodb. Check out this post https://www.linkedin.com/pulse/5-way-sync-data-from-mongodb-es-kai-hao for integration. For me I used the river option (option 3) in the linked post, but as you may see that is now deprecated for 2.0x version. Once this integration is done, you can create custom dashboard in Kibana based on the data you have and voila!

Data Modelling

Here I am hoping you have some basic knowledge of Mongodb or atleast understand how JSON works.

Testing Report

A testing report is basically number of testcases that passed and failed on a particular release deployed on a specific environment. This can be modelled as :

{
	"id": "<uuid>",
	"environment": "<string>",
	"release": "<releaseId>",
	"bugs": ["<bugId>", "<bugId>", "<bugId>", "<bugId>", "<bugId>"],
	"result": {
		"passed": ["<testCaseId>", "<testCaseId>", "<testCaseId>", "<testCaseId>"],
		"failed": ["<testCaseId>", "<testCaseId>", "<testCaseId>", "<testCaseId>"]
	},
	"timestamp": "<date>"
}

Test Case

Test case is just the description of the scenario that will be tested, expected outcome and feature to which it maps.

{
	"id": "<uuid>",
	"description": "<string>",
	"expected": "<string>",
	"features": ["<featureId>", "<featureId>", "<featureId>"],
	"timestamp": "<date>"
}

Release

Release is basically the latest stable working tag of software which has some new features and follows an increment style i.e. build upon last release.

{
	"id": "<uuid>",
	"tagVersion": "<string>",
	"incrementedOn": "<releaseId>",
	"features": [{
		"id": "<uuid>",
		"description": "<string>"
	}, {
		"id": "<uuid>",
		"description": "<string>"
	}, {
		"id": "<uuid>",
		"description": "<string>"
	}],
	"timestamp": "<date>"
}

Bug

Bug is an anamoly found in functionality of software during testing cycle. It maps to a feature and may or may not present in multiple releases.

{
	"id": "<uuid>",
	"introducedIn":"<releaseId>",
	"presentIn": ["<releaseId>", "<releaseId>", "<releaseId>"],
	"features": ["<featureId>", "<featureId>", "<featureId>"],
	"timestamp": "<date>"
}

Conclusion

With the above explained data models and tools one can have a minimal testing portal up and running in just a day, all is left to prepare the metadata and feed it to mongodb.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.