September 11, 2020

Types of Method Parameter in C#

 Basically in C# , there are four types of Parameters -

Value Parameter- 

Create a copy of parameter passed, so modification will not affect each other.

Reference Parameter-

 The ref method parameter keyword on method parameter causes a method to refer to same variable that was passed into the method. Any changes made to the variable will be reflected in that variable when control passes back to the calling method.

Out Parameter-

 Use when you want a method to return more than one value

Parameter Arrays

The Param keyword lets you specify a method parameter that takes a variable number of arguments. Param keyword should be the last one in a method declaration.

Here is the Example-

int[] numbers = new int[4];

            numbers[0] = 137;

            numbers[1] = 138;

            numbers[2] = 139;

            numbers[3] = 140;

           parammethod();

            parammethod(numbers);

            parammethod(1, 2, 3, 4, 5);

            int j = 20;

            int k = 0;

            simplemethod(j);

            Console.WriteLine(j);

            simplemethod(ref k);

            Console.WriteLine(k);

             int total = 0;

            int product = 0;

            calculate(10, 20, out total, out product);


            Console.WriteLine("sum={0} && Product={1}", total, product);

}

         public static void calculate(int a, int b, out int sum, out int product)

        {

            sum = a + b;

            product = a * b;


        }

        public static void simplemethod(ref int i)

        {

            i = 10;

        }

        //you can not have two param and it should be at the end 

        public static void parammethod(params int[] numbers)

        {

            Console.WriteLine("the total numbers are {0}", numbers.Length);

            foreach (int i in numbers)

            {

 Console.WriteLine(i);

        }

Difference Between For and ForEach

ForEach loop - It is used to iterate through the items in a collection.  Foreach is very efficient. you do not need to know how many elements in collection.

For loop - We do intialisation, condition and increment at same place . you have to know how many times you have to loop through. we can use an exception as well.

Here is the example-

int[] numbers = new int[4];

            numbers[0] = 137;

            numbers[1] = 138;

            numbers[2] = 139;

            numbers[3] = 140;

            foreach (int k in numbers)

            {

                Console.Write(k);

            }

            for (int j = 0; j <= numbers.Length; j++)

            {

                Console.WriteLine(numbers[j]);

            }


In this, in case of for loop , if by mistaken we use <= symbol instead of < , we will get indexOutOfRange exception. So pretty much , best to use foreach loop...

Difference between Parse and TryParse

 If a number in a string format you have two options to convert into int or string 

1. Parse--Parse() method throws an exception if it can not parse the value 

2. TryParse()- TryParse() method returen a boolean whether it is succeeded or failed.

Use Parse() if you are sure value is valid, otherwise use TryParse.. 


For example- We are using TryParse beacuse our number is invalid.

string num= "100lk";

int result= 0;

bool isConversionsuccessful= int.TryParse(num,out result)

if(isConversionsuccessful)

{

Console.Writeline(result);

}

else

{

Console.Writeline("Please enter valid number");

}

Best Automation Testing tools


Best Tools For Automation-


Selenium- For developers and testers who have experience and skills in programming and scripting, Selenium offers flexibility that is unseen in many other test automation tools and frameworks. Users can write test scripts in many different languages that run on multiple system environments  and browsers 

Katalon Studio- Katalon Studio is a powerful and comprehensive automation solution for testing API, Web, mobile, and desktop application testing. It also has a rich feature set for these types of testing and supports multiple platforms.


Cypress for automation-
Cypress provides a robust, complete framework for running automated tests but takes some of the freedom out of Selenium by confining the user to specific frameworks and languages.


Postman for API- Postman is another automation tool designed for API testing. Users can install this tool as a browser extension or a desktop application on Mac, Linux, Windows. It is popular not only among testers for API test automation but also developers who use the tool to develop and test APIs. It is, in fact, a development environment to develop and test APIs.

Soup UI for API-Soup UI is a headless functional testing tool dedicated to API testing.


Apache JMeter-JMeter is an open-source tool designed for test loading and performance measurement — two features of which JMeter is known.

WebLOAD supports hundreds of technologies – from web protocols to enterprise applications and has built-in integration with Jenkins, Selenium and many other tools to enable continuous load testing for DevOps. 

LoadNinja is a cloud-based load testing and performance testing platform for web applications and web services.




Why we need test automation ?

It seems simple, but the answer is quite tedious. I would say the purpose of automation is to make sure that the application is working properly and is meeting the functions requirements specified in the business requirement Specification. When test engineers run automation suits in this continuous deployment world, the automation suites needs to make sure that the application is not broken. The main purpose of Automation is to bring faster validation for phases in the development of your product and finding and preventing defects.

Basic Concepts of OOP's and C#

Basic Concepts---


1. What is OOP?

Object Oriented Programming

2. Can you write the basic concepts of OOP's?

(I personally think this is not a question to ask, but people do ask these kind of questions.)

Abstraction

Encapsulation

Inheritance

Polymorphism

3. What is a class?

A class is a broad definition of something, an instance (or object) is a specific example that fits under that broader class definition. e.g. TV is a class, and my Samsung TV is my instance.

4. What is an object?

It is the actual instance of a class. e.g. Car is class, Mercedes Benz is an instance.

5. What is Encapsulation?

The Class can encapsulate the details of the logic.


6. What is Polymorphism?

class Employee {

public int getDiscount() {

return 5;

}

}

class InternalEmployee : Employee {

public int getDiscount() {

return 10;

}

}

class Contractor : Employee {

public int getDiscount() {

return 20;

}

}

Employee employee = new Employee();

employee.getDiscount(); // returns 5

Employee employee1 = new InternalEmployee();

employee1.getDiscount(); // returns 10

Employee employee2 = new ContractEmployee();

employee2.getDiscount(); // returns 20

As you see, although the variables have been declared with the same type Employee, and depends its actual initialisation, the same method will be executed differently.

So Polymorphism: Objects may behave differently depending on the "type" while keeping the same interface. we use getter and setter methods to encapsulate and protect fields.

7. What is Inheritance?

One class can extend the features of the other Class, and the first class will be the sub class, usually it implies a more specific type of entity. e.g. Dog is subclass of Pet. Dog is more specific whereas Pet can contain some common features of Pet. This way when I create a class called Cat, I do not need to repeat everything Pet has already got.

We can achieve multiple class inheritance using interfaces that solves diamond problem.

8. Why Properties?
Making the class field is public, exposing it to external world is bad as you will not have controlled over what have assigned and returned.

9. Define a constructor?
Constructor is a method used to initialize an object, and it gets invoked at the time of object creation.
The creation of an object involves allocating the right amount of the memory.

10. Define Destructor?
Destructor is a method which is automatically called when the object is destroyed. You can clean up things there if needed.

11. What is a delegate?
A delegate is a point safe function pointer. It holds a reference pointer to a function.

12. What is a virtual method?
Virtual method is a member method of class and its functionality can be overridden in its derived or subclass class.

13. What is overloading?
Same method name, but different number or type of parameters.
e.g.
void add(int a, int b);

void add(double a, double b);

void add(int a, int b, int c);

14. What is an abstract class?
An abstract class is a class which cannot be instantiated.
It will be inherited by specific type or class. (A type is a class, a class is a type)
An abstract class can contain only Abstract method.
for example-
public abstract class Customer
{
public abstract void print();
}
public class Program: Customer 
{
public override void print()
{
Console.Writeline("Print Method");
}

public static void main()
{
Customer c= new Program();
c.print();

}
}


15. What is a ternary operator?

condition ? expr1 : expr2

If condition is true, expr1 is executed otherwise expr2 will be executed.

16. What is method overriding?

Method overriding is a feature that allows sub class to provide implementation of a method that is already defined in the main class. This will override the implementation in the super class by providing the same method name, same parameter and same return type.

17. What is an interface?

An interface is a contract. An interface is a collection of abstract method. If the class implements an inheritance, and then thereby inherits all the abstract methods of an interface.

18. What is exception handling?
Exception is an event that occurs during the execution of a program. Exceptions can be of any type – Run time exception, Error exceptions. Those exceptions are handled properly through exception handling mechanism like try, catch and throw keywords.

19. Difference between class and an object?

An object is an instance of a class. Objects hold information , but classes don’t have any information. Definition of properties and functions can be done at class and can be used by the object. Class can have sub-classes, and an object doesn’t have sub-objects.

20. What is early and late binding?

Early binding refers to assignment of values to variables during design time whereas late binding refers to assignment of values to variables during run time.

Every Console application should have a console method.

21. what is nullable type?

A nullable type can represent the correct range of values for its underlying value type, plus an additional null value.

The C# Null Coalescing Operator (??) is a binary operator that simplifies checking for null values. It is used to assign a default value to a variable when the value is null.
class Program

{

static void Main(string[] args)

{

string name = null;

string myname = name ?? "abc";

Console.WriteLine(myname);

Console.ReadLine();

}

}


22. What is an array?

An array is collection of similar data types.

23. Difference between Abstract classes and interfaces

The abstract keyword is used to create abstract classes. It can not be instantiated and can not be used as base class , not sealed class.

Abstract classes can have implementations for some of its members but the interface can not have implementation for any of its members.

Interface can not have fields where as as abstract class can have fields .

A class can inherit from multiple interfaces at the same time , where as a class cannot inherit from multiple classes at the same time.

Abstract class members can have access modifiers where as an interface members can not have access modifiers.

24. Difference between Abstract class and Sealed Class?

abstract means a class can be used as base class
sealed means class can not be used as base class

25. What is Enums?
Enums- If a program use set of integral numbers, consider replacing them with enums , which makes the program more readable, maintainable. these are strongly typed constants.

26. Difference between implicit and explicit conversion?

Implicit conversion- It is done by compiler when there is no loss of information if the conversion is done .

for example- Converting an int to float will not loose any data.

Explicit Conversion- For example- when we convert a float into int , we loose the fractional part and also a possibility of overflow exception.In this case , explicit conversion is required. We can use cast operator.

27. What is lambda Expression?

lambda Expressions- Anonymous methods => is called lambda operator. for example- to find an employees id with id=1

you can use lambda expression-

Employee em= listEmployee.Find((Employee em)=>em.id == 1);

28. Static member and static method-

Static member- when a class member is declared with static keyword is called static member. If I create 3 objects of a class, I will have 3 sets of instance members in the memory, where as there will be one copy of static member, no matter how many instances of class are created.

Static method:
Two common uses of static fields are to keep a count of the number of objects that have been instantiated, or to store a value that must be shared among all instances.

 Static methods can be overloaded but not overridden, because they belong to the class, and not to any instance of the class.

Static methods cannot be overridden, they can however be hidden using the 'new' keyword. Mostly overriding methods means you reference a base type and want to call a derived method. Since static's are part of the type 

Static method some cases we have specific method we do not need to create object of class
We do not need to create object all the time. blueprint we can avoid allocate the memory in our application by not need to create an object

29. What is Structs?
Structs is a value type where class is a value type. Struct are stored on stack where classes are stored on heap.

30. what does Type and Type member mean?
Classes, Structs, delegates, enums and interfaces are called as types and fields, properties , constructors and methods that normally reside in the type are called type members .

31. what are access modifiers?
Private - Only within the containing class 
Public - Anywhere 
Protected -  Within the containing type and type derived from the containing type 
Internal - A member with an internal modifier is available anywhere within the containing assembly  

32. What are attributes?
Attributes allows you to add declarative to your programs. For example-obselete 

33. what is Dictionary?
A dictionary is the collection of key value pair.
When we create a dictionary , we have to specify the type for key and value.

For example-
using System;
using System.Collections.Generic;
namespace Dictionary
{
   public  class Program
    {
        private static void Main(string[] args)
        {
            Customer c1 = new Customer()
            {
            id = 100,
            name = "krtishma",
            salary = 20000
        };
 Customer c2 = new Customer()
        {
            id = 101,
        name = "hari",
            salary = 300000
           };
`    Customer c3 = new Customer()
        {
            id = 103,
        name = "Reami",
            salary = 400000
             };
          Dictionary<int, Customer> diccustomer = new Dictionary<int, Customer>();
            diccustomer.Add(c1.id, c1);
            diccustomer.Add(c2.id, c2);
            diccustomer.Add(c3.id, c3)
    Customer cust;
            if (diccustomer.TryGetValue(111, out cust))
            {
                Console.WriteLine("ID ={0} Name ={1} salary ={2}", cust.id, cust.name, cust.salary);

            }
            else {
                Console.WriteLine("key not found");
            
            }
            Customer customer103 = diccustomer[103];
            //instead of key value pair we are using var
            foreach (KeyValuePair<int, Customer> CustomerKEyvaluepair in diccustomer)
            {
                Console.WriteLine("ID ={0}", CustomerKEyvaluepair.Key);
                Customer cus = CustomerKEyvaluepair.Value;
                Console.WriteLine("ID={0}name ={1} Salary ={2}", cus.id, cus.name, cus.salary);
 }
            foreach (Customer cus in diccustomer.Values)
            {
                Console.WriteLine("ID ={0} Name ={1} salary ={2}", cus.id, cus.name, cus.salary);
            
            }
            foreach (int key in diccustomer.Keys)

            {
                Console.WriteLine(key);
                
                // Console.WriteLine("ID ={0}", CustomerKEyvaluepair.Key);
                //Customer cus= CustomerKEyvaluepair.Value;
                //Console.WriteLine("ID={0}name ={1} Salary ={2}",cus.id,cus.name,cus.salary);


            }
public class Customer
        { 
        public int id { get; set; }
            public string name { get; set; }
            public int salary { get; set; }
}
        
        
33. What is list?
List is generic collection class can be used to create a collection of any type. we can sort a list , reverse a list, contains, start with different methods we can use..
public  class Program
    {
        private static void Main(string[] args)
        {

            Customer c1 = new Customer()
            {
            id = 100,
            name = "krtishma",
            salary = 20000

        };


        Customer c2 = new Customer()
        {
            id = 101,
        name = "hari",
            salary = 300000
            
            };

            List<Customer> customers = new List<Customer>(2);
            customers.Add(c1);
            customers.Add(c2);
           Console.WriteLine("are salary greater than 5900",customers.TrueForAll(x => x.salary > 4000));
            //if (customers.Contains(c2))
            if(customers.Exists(cus=>cus.name.StartsWith("p")))
            {
                Console.WriteLine("");

            }
            else {
                Console.WriteLine("");
            
            }

HOW TO RESIZE AN ARRAY- 
array.resize(ref arrayname, 7);


public bool method(string color)
return ( color.tolower()== "green" ) ? true: false 




            
       
























September 08, 2020

DI/CI Specflow



Dependency Injection-

Dependency Injection is a techniques whereby one object supplies the dependency of another object. Dependency is an object that is used as a service.

For example- At left hand side image , Chef says I need objects a and b. The waiter does not know anything about a and b . Dependency injection acts like a window between waiter and Chef. Objects are in DI that is hidden. Window is going to create object a and b but you cant see that. At right hand side , you can see waiter gives the object a and b to the Chef.


Context Injection-

SpecFlow supports a very simple dependency framework that is able to instantiate and inject class instances for scenarios. This feature allows you to group the shared state in context classes, and inject them into every binding class that needs access to that shared state.

To use context injection:

Create your POCOs (Plain old C# Object)(simple .NET classes) representing the shared data.

Define them as constructor parameters in every binding class that requires them.

Save the constructor argument to instance fields, so you can use them in the step definitions.

In this example we define a POCO for holding the data of a person and use it in a given and a then step that are placed in different binding classes.

public class PersonData // the POCO for sharing person data
{ 
  public string FirstName;
  public string LastName;
}

[Binding]
public class MyStepDefs
{
  private readonly PersonData personData;
  public MyStepDefs(PersonData personData) // use it as ctor parameter
  { 
    this.personData = personData;
  }
  
  [Given] 
  public void The_person_FIRSTNAME_LASTNAME(string firstName, string lastName) 
  {
    personData.FirstName = firstName; // write into the shared data
    personData.LastName = lastName;
    //... do other things you need
  }
}

Scenario Context-

You may have at least seen the ScenarioContext from the code that SpecFlow generates when a missing step definition is found: ScenarioContext.Pending();

ScenarioContext provides access to several functions, which are demonstrated using the following scenarios

Feature Context-

SpecFlow provides access to the current test context using both FeatureContext and the more commonly used Scenario Context. 
Feature Context persists for the duration of the execution of an entire feature, whereas Scenario Context only persists for the duration of a scenario.

September 07, 2020

Azure Devops



What is Azure?


Azure is cloud computing platform provided by Microsoft.

It is growing collection of integrated cloud services which Developers and IT professionals use to build, deploy and manage application through the global network of Data Centers.

All these providers provide services . 100+ services are available in 140 countries.

Azure Features -


1. On demand Provisioning- Ask for what you need, when you need and when to stop. If you want to scale an application then it will not take time .

2. Scalability in Minutes- Scale up or down, out or in depending upon usage or needs. for example- In e-commerce sites, like in festive seasons, you can scale up and not in festive seasons, you are able to scale down.

3. Pay as you Consume- You pay for only number of provisions you are using.

4. Abstract Resources- Focus on your application . You do not need to worry about hardware specifications and  networking. All things are taken care by Azure.

5. Efficiency of experts- Utilize the skills , knowledge and resources of experts

6. Measurable- Every unit of usage is measurable

Azure Services -


1. Compute - what kind of compute options are available. Virtual machines, app services , Data bricks.

2. Migration- if you want your storage or data . Different service available to migrate into cloud. you can move a part of your application and hybrid option is available

3. Secure - Azure is very secure and very much complained with organisational policy.

4. Storage- for example - you tube files SQL, MySQL ,DBMS, you want to store video and audio files are available in Azure

5. Messaging- Messaging based architecture like two application running separately and you want to scan send out message to each other

6. Networking- u can make cloud environment as secure as you want to be.

What is Devops -


Devops is set of practices intended to reduce the time between committing a change to the system and change being placed into the normal production, while ensuring high quality. Operations and developers come together.

The DevOps is the combination of two words, one is development and other is Operations. It is a culture to promote the development and operation process collectively.

The DevOps tutorial will help you to learn DevOps basics and provide depth knowledge of various DevOps tools such as Git, Ansible, Docker, Puppet, Jenkins, Chef, Nagios, and Kubernetes.
what is Azure Devops-

Azure DevOps Server is a Microsoft product that provides version control, reporting, requirements management, project management, automated builds, testing and release management capabilities.

All set of tools integrated into one single environment .

Components in Azure Devops-


1. Azure Board- IT is the service for managing the work for your software projects. It brings a set of capabilities including native support for scrum, Kanban and customizaable dashboards and integrated reporting. 

2. Azure Pipelines— A CI/CD, testing, and deployment system that can connect to any Git repository

3. Azure Repos— A cloud-hosted private Git repository service

4. Azure Test Plans— A solution for tests and capturing data about defects

5. Azure Artifacts — A hosting facility for Maven, Npm, and Nu Get packages


August 26, 2020

Assertions in Jmeter



Assertions in very simple words is check on response.

we test the format of response and time took to the response . All these checks are called Assertions.

There are lots of assertions in JMeter -

1. Response Assertion- The response assertion lets you add pattern strings to be compared against various fields of the server response. We can check response code 200 then it should pass .

2. Duration Assertion- The Duration Assertion tests that each server response was received within a given amount of time. you see duration in milliseconds . Just compare with response.

3.Size Assertion- The Size Assertion tests that each server response contains the expected number of byte in it. You can specify that the size be equal to, greater than, less than, or not equal to a given number of bytes. Size comes in bytes.

4. HTML Assertion- We are checking the format of response .Is it html format or not? we can provide error Threshold and Warning threshold in our HTML assertion. We can log the errors in a file .It is useful if web application has third party app and they have to talk to each other , these issues can be resolved .

5. XML Assertion- IT is a check on Xml format.

6. XPath Assertion- It is useful with API . We can assert some xpath.







August 25, 2020

Test Tool types



The various types of test tools according to the test process activities are:

Tool support for management of testing and tests:
Test Management Tools
Requirement Management Tools
Incident Management tools
Configuration Management tools

Tool support for static testing:
Review Process Support tools
Static analysis tools
Modelling tools


Tool support for test specification:
Test Design tools
test data preparation tools

Tool support for test execution and logging:
Test execution tools
Test Harness tools
Coverage measurement tools
Security tools

Tools support for performance and monitoring:
Dynamic analysis tools
Performance testing tools
Load testing and stress testing tools
Monitoring tools


August 23, 2020

SCRUM PROCESS



Agile software development refers to a group of software development methodologies based on iterative development, where requirements and solutions evolve through collaboration between self-organizing cross-functional teams.

These are the main terms are used in Agile:

EPIC- It is a larger requirement that can be broken down into small tasks.

Story-It is a small requirement called user stories

Task - It is action that we need to complete for particular story

Agile Roles-

Product owner- Getting the requirements from the customer or stakeholder . He will define the features of the product and creating epic and stories and prioritize the stories, accept and reject work products.

Scrum Master- who drives the whole agile process. how working is going on..how we can overcome the challenges .

Scrum Team- Developers and Testers . Both work together

Definition of Ready- No of rules --suppose story is ready for testing , user story is clear, testable, feasible, defined, acceptance criteria defined, Performance criteria identified

Definition of Done- It also defines certain rules code produced, code commented, peer reviewed,build without errors, unit testing written,Deployed to system test environment ,passed UAT, Relevant documentation

Product Backlog- Prepare by product owner which contains the requirements .

Product owner will prioritize the stories and all stories have been developed and delivered to customers . In release planning decide how many sprints are required

Product owner and scrum master then have a meeting . he will contain the product backlog. Before sprint is starting, we need to plan the sprint.

In sprint planning meeting developer and QA will be there and they will go through each story and give estimation point or story point estimation. estimation is given in the form of Fibonacci series(1,2,3,5,8,---).they will decide what all stories needs to be complete.

Sprint backlog- It contains the committed stories .

For example- We have 3 months of times. We divide entire cycle into multiple parts called sprints or iterations.

In sprint Planning- what is the story and what will be the tasks of each team..

Every day there is a meeting of 15 mins that is called Scrum meeting .

They will discuss about the status and any blockers if they have.

Once Sprint is completed , we have to give demo to product owner and QA team. whether product is meet to customer requirements. After completion of sprint, Sprint retrospective meeting is done . what went wrong? what went well? improvement areas.

This is complete Scrum life Cycle..














August 21, 2020

logic Controllers in Jmeter

 Controllers-

Loop, Simple, Module, Include,Random

Loop Controller-

Logic Controllers let you define the order of processing request in a Thread. It lets you control "when" to send a user request to a web server. For example, you have 3 requests and you want to set up loop for each request differently so with the help of loop controller we can do this easily.

Here I have added two requests and before one request, I have added loop count with 5 and I want to run first request 5 times and second request only one time.





Simple Controller-

Simple Controller is just a container for user request. We can use Test Fragment as the alternative of Simple Controller.






Module controller-


This functionality can be stored in Simple Controller as "modules". Module Controller will choose which module needs to run.





for Example-we have used Login request which is in Simple modular inside Module Controller.




Include Controller -
Export this test fragment and can include anywhere . For example- I have saved this file Login.jmx in test fragment and disable module controller and created include controller and browse the file login.jmx and move include controller before register request. we can remove Module Controller.







Random Controller-



A Random Controller will make one of samplers contained in it run in each loop of the thread and this sampler will be randomly selected.








August 20, 2020

Timers in Jmeter


Timers in Jmeter -


A jmeter thread by default will send requests continuously without any pause. If we want to perform load , it will be overloaded .To get a pause between the requests , timers are used. The purpose of timers is to simulate real users actions in behavior.

Some of the Timers used are
Constant Timer
Gaussian Random Timer
Synchronizing Timer
Uniform Random Timer
For example-- suppose I have 3 requests and when I run I am getting response immediately but in real scenario I have to set up timer. let see how to add timer.



Constant timer-


At Thread group I have added constant timer and u can see the time has been changed to 15 sec as I have given time in constant timer that is 5000 ms. each request is running after 5 sec.



Uniform Random timer- Basically takes random time for each request. It is used when you wants to put some fixed but some random time delay between 2 requests in software load test plan. For example- I want to put minimum delay time 3 seconds and maximum delay time to 10 seconds then i can use uniform random timer in my test plan.


Random delay - we get random delay
Constant delay offset


How to add elements??



Step 1: Create a Thread Group (Right Click Test Plan – Add – Thread -Thread Group)



Step 2: Create a HTTP Request (Right Click Thread Group – Add – Sampler -HTTP Request)



Step 3: Create a Listener (Right Click Thread Group – Listener – View Results Tree)



Step 4: Create a Listener (Right Click Thread Group – Listener – Summary Report)



Step 5: Create a Listener (Right Click Thread Group – Listener – Generate Summary Report)



Step 6: Create a Listener (Right Click Thread Group – Listener – View Results in Table)















Components in Jmeter



There are different components of JMeter are called Elements that serve their own purpose.
Thread Group-

Thread Groups is a collection of Threads.

Each thread represents one user using the application under test.

Basically, each Thread simulates one real user request to the server.
Listeners-

Listeners: shows the results of the test execution.

They can show results in a different format such as a tree, table, graph or log file.
Samplers-

Samplers are different types of request send by thread group.

We already know that Thread Groups simulate user request to the server
Configuration Elements-

set up defaults and variables for later use by samplers. For example- CSV Data config, HTTP request, FTTP Request


JMeter



What is JMeter?

The Apache JMeterTM is pure Java open source software, which was first developed by Stefano Mazzocchi of the Apache Software Foundation, designed to load test functional behavior and measure performance.

You can use JMeter to analyze and measure the performance of web application or a variety of services.


Throughput- amount of data transported to the server in respond to the client  request in given period of time . IT depends on degree of parallelism.

Benefits of Load Runner- versatile result , easy integration 

Endurance testing- IT is non functional type. To evaluate the behaviour under sustained use.

Spike Testing- estimate the weekeness of the system

Common mistakes done by user in performance testing - not validating the test results, lacking long duration sustainability test, n/w bandwidth not being simulated 

August 18, 2020

Integration Testing

Here are some slides which are useful to understand the concept of Integration testing and difference between Big bang (non incremental)and top-down and bottom up approach(incremental).

compose =sent box 










Verification vs Vadidation vs Testing

Verification- 

The objective is to make sure product is as per requirements and design specifications.

It is the static testing 

 Are we building the product right?

It does not include the execution of code


Validation- 

The objective is to making sure that products meet user's requirements.

 Are we building the right product?

It includes execution of code

It is type of dynamic testing

Testing- 

The process of exercising software to verify that it satisfy specified requirements and to detect faults.

crs- srs= hld-lld=coding- white box testing (devpr)= fnal=integration-sys- accepatance




August 15, 2020

Review Types

 Review types --

Informal Review -Generating new ideas or solutions, quickly solving minor problems

Walk through- Exchanging ideas about techniques or style variations, training of participants

Technical Review - Evaluate quality and building confidence in the work product and generating new ideas and considering alternative implementations

Inspection- Motivate authors to improve work products and achieving consensus 


Here is the list of tasks which is performed in each type of review-


Roles and Responsibilities in formal Review

 Author- 

Who creates the work product and fix the defects

Management- 

Review planning, defining scope, selecting people, checking entry and exit criteria, Budget and time, ongoing cost effectiveness , execute control decisions

Facilitator-

 Effective running of the meeting, make sure no conflict occur. Success depends on Facilitator.

Review Leader- 

Decide who will be involved in the meeting and when and where it will take place.

Reviewer-

 Person working on project or any stakeholder

Scribe-

 Collects potential defects 




 







Common types of Test Strategies

 1.Analytical-

This type of test strategy is based on an analysis of some factor (For example-requirement or risk). Risk-based testing is an example of an analytical approach, where tests are designed and prioritized based on the level of risk.

2.Model-Based-

 In this type of test strategy, tests are designed based on some model of some required aspect of the product, such as a function, a business process, an internal structure, or a non-functional characteristic (for example- reliability).

3.Methodical-

This type of test strategy relies on making systematic use of some predefined set of tests or test conditions, such as a taxonomy of common or likely types of failures.

4.Process-compliant -

This type of test strategy involves analyzing, designing, and implementing tests based on external rules and standards, such as those specified by industry-specific standards

5.Directed -

 This type of test strategy is driven primarily by the advice, guidance, or instructions of stakeholders, business domain experts, or technology experts, who may be outside the test team or outside the organization itself.

 6.Regression-averse-

 This type of test strategy is motivated by a desire to avoid regression of existing capabilities. This test strategy includes reuse of existing testware, extensive automation of regression tests, and standard test suites. 

7.Reactive-

In this type of test strategy, testing is reactive to the component or system being tested, and the events occurring during test execution, rather than being pre-planned (as the preceding strategies are). 

Key concepts in Pipeline

 1. Agent- To build your code or deploy your software using azure pipelines, you need at least one agent. Two types of agent- Microsoft host...