Software Testing: we have to perform actions and actions are giving expected results or not. Ex: Tv and mobile expectations reaching or not. Testing we will do professionally whatever we do regularly we have to perform professionally by using certain methods. we will get requirements we have to understand the requirements and perform actions olden days because no testing many failures every day testing is necessary. if build is not working for automation testing then we should do manual testing. bug or defect: Deviation from the expected result to actual result. API Testing: Application Programming Interface -- Postman URL: Unified Resource Locator. URI: Unified Resource Identifier Black Box Testing -- Testing done by the testers. White Box Testing -- Testing done by the developers.. Database Testing -- SQL-- structured Query Language-- we have simple commands Automation Testing --- Test scripts understood by tool. we have different libraries and object repositories. Third party tools Manual Testing: Requirements -- understand the requirements --- Prepare test scenarios-- Prepare test cases- build -- execute test cases -- bugs/defects --- assign to developers --- zero bugs or defects --- product will be in production. Software : Collection of computer programs that help us to perform a task Types of software: System software: Keyboards, mouse, printers to install some software Ex: Device drivers, Operating systems, servers, utilities Programming software: compilers, debuggers, interpreters .compilers - Process input and produce output Application software: Web applications, mobile application, desktop applications Web applications-- internet -- Facebook, amazon Desktop applications-- without internet -- calc, notepad xbank -- Manually they want some software IT company --- Develop --test -- deliver -- xbank. Testing delivery quality product to the customer. Project Vs product: If software application is developed for specific customer based on the specific requirements then it is called project. Ex: only bank customers sbi If software application is developed for multiple customer based on the market requirements then it is called product. Ex: WhatsApp, Excel, word Service based companies: HCL Product based companies: Google, Microsoft. Error: Human mistake typing Bug: Deviation from the expected result Failure: End user action at client place not working. why the software has bugs? 1. Miscommunication or no communication 2. Programming errors 3. Changing requirements - major cause 4. Lack of skilled testers. Manual Testing concepts: ========================== SDLC process Agile Development Methodology: very imp to sustain in software industry, user stories, how much time, test engineer Testing basics Different types of testing Functional testing/unit testing/system testing/performance testing/security testing. Functional testing and non functional testing. NFT- usability testing, UI testing, recovery/compatibility testing etc what is test plan/test strategy?: time, resources, test cases Test case preparation: detailed steps of execution process as part of functionality what are the tools we use-- different techniques Ex: priority and severity to write test cases especially with test data. Boundary value analysis, Test Execution: Recognized try to identify as many validations. Defect management: raise bug, assign to developers , conflict the issues--screenshots. Test metrics: how many test cases are done how much it is completed. Jira -- project execution tracking tool API Testing -- Application programming interface. Automation Testing Concepts: ============================ Core java -- widely used Selenium -- tool Automation Frameworks--TestNG and cucumber framework Frame work concepts Data driven concepts Modular approach -- categorize the test cases POM--- create an object repository, address of web elements any changes go directly to POM and change BDD(Behavior Driven Development) -- non technical people Rest Assured libraries. SDLC: Software Development Life cycle SDLC is a process used by software industry to design, develop and test software. Any company 3P's are imp P - People P - Process P - Product/Project. Waterfall model is a linear model - Documentation will play an important role Based on the requirements design will be done, HLD, LLD. Each phase depends on the previous phase. Advantages: 1. Quality of the product will be good 2. Since requirement changes are not allowed chances of finding bugs will be less 3. Initial investment is less since the testers are hired at later stages. 4. Preferred for small projects where requirements are freeze. Disadvantages of waterfall model: 1. Requirement changes are not allowed. 2. If there is defect in requirement that will be continued in later phases. 3. Total investment is more because time taking for rework on defect is time consuming which leads to high investment. 4. Testing will start after coding. SPIRAL MODEL: 10 requirements -- one release and one software is developed. 5 new requirements - accommodate the new requirements Its preferred by product based companies Every time new feature is getting added. Spiral model is iterative model. spiral model overcome drawbacks of waterfall model. we follow spiral model whenever there is dependency of modules. Ex: Gmail : compose mail and sent mail In every cycle new software will be released to the customer. software will be released in multiple versions so it is also called version control model. Advantages of spiral model: 1.Testing is done in every cycle before going to the next cycle. 2.customer will get to use the software for every module. 3.Requirement changes are allowed after every cycle before going to the next cycle. Disadvantages: 1.Requirement changes are not allowed in between the cycles. 2. Every cycle of spiral model looks like waterfall model. 3. There is no testing in requirement and design phase. Prototype: Blue print of the software initial requirements from the customer -- prototype Module: Module is nothing but a piece of software which contains some functionalities. Entire software is divided into modules . Different developers will work on different modules Gmail Login Inbox compose sent receive mail Banking application: ==================== Login check balance fund transfer or withdrawn request statement Add payee V-Model//VV Model(Verification/Validation model) ================================================= Specialty of v model is in every phase we conduct testing. SRS/BRS - system requirement specification or Business requirement specification is prepared by product manager or Business analyst. HLD -- High level design LLD -- Low level design coding: unit testing will be done by developers Integration testing -- coding will be there it is done by developers system testing-- Done by testers here no need to know the code. UAT-- user acceptance testing - customers and testers will do testing. Static Testing ================ Testing the project related documents is called static testing. 3 methods --------- Review walkthrough inspection Dynamic Testing--- Testing the actual software unit testing integration testing system testing UAT until and unless coding is not ready we can't do dynamic testing. system testing-- Expected Result = Actual Result done by testers UAT-- End users along with testers one side -- static testing and other side -- Dynamic testing. 1. Verification checks whether we are building right product or not 2. Focus is more on documentation any one can do we use static testing techniques. 3. Validation checks whether we are building right product or not 4. Focus is on software and we use dynamic testing. white box testing -- Testing done by developers verification is done before software is ready and validation is done after software is ready. Advantages: 1. Testing is involved in each and every phase. Disadv: 1. Documentation is more 2. Initial investment is more. AGILE METHODOLOGY ================== Agile is basically iterative and incremental model. Iterative :same process we follow again and again Design, coding and testing Incremental Model: Number of features keep on adding -- new modules keep on getting added. Agile process advantage is we will deliver the piece of software with few functionalities. customer don't wait for long time till complete software is ready. 5-10 features -- develop and release as version one V1 another 10 features -- develop and release as version V2 we can accommodate changes in the requirements. Agile principles: 1. Customer no need to wait for the long time. 2. we develop, test and release piece of software to customer with few number of features. 3. we can accept/accommodate requirement changes. Good communication between developer, tester and client . Delivery is very fast in agile process with in 2 weeks or 3 weeks a delivery will be done. Advantages: 1. Requirement changes are allowed in any stage of development or we can accommodate requirement changes in the middle of development. 2. It is very easy model to adapt 3. Customer no need to wait for the long time 4. Good communication between developer, tester and client . 5. Delivery is very fast Disadvantage: Less focus on design and documentation since we deliver software very fast. Scrum ===== Scrum is a kind of framework through which we develop software product by following agile principles. Agile is a defined process with some principles. scrum is how to follow principles. Scrum Team: 5 to 9 1.Product owner 2.scrum master 3.Dev Team 4.QA Team Agile -- All these people has common goal to deliver quality product. Product Owner: 1.Define the features of the product 2.Prioritize the features according to market value. 3.Adjust features and priority every iteration as needed. 4.Accept or reject work results Scrum master: The main role is facilitating and driving the agile process. He make sure that everybody is following agile process. and every step scrum master will take care. Developers: Develop the code Testers: Test the code Scrum Terminology: ================= user story: A Feature/model in software Epic : Collection of user stories Product owner will define the feature in the form of user story. Product backlog: contains the list of user stories prepared by product owner. Sprint/Iteration: Period of time to complete the user stories decided by the product owner and team usually 2-4 weeks of time. with in this time we will deliver a piece of software to customer with some functionality. Sprint planning Meeting: Meeting conducted with in the team to define what can be delivered in the sprint and duration. Sprint backlog: List of committed stories by Dev/QA for specific sprint. For each sprint backlog will change. Scrum call/ standup : Meeting conducted by scrum master everyday 15min 1.what did you do yesterday? 2.what will you do today 3.Are there any impediments in your way? Sprint Retrospective meeting: Only once after completion of sprint. The entire team including both scrum master and product owner should participate. 1.what went well 2.what went wrong 3.what are the improvements needed in upcoming sprint. Story point: Rough estimation of user stories it will be given by dev and qa team Burndown chart: shows how much work is remaining in the sprint. Maintained by the scrum master daily. In sprint review: we will conduct the demo to the product owner. Deliver the piece of software to the customer. Scrum board: Different stages of the task. Now a days with the help of jira tool. Evey user stoy must have some acceptance criteria. Key Responsibilities of a QA Engineer ====================================== Responsibilities 1. understanding the functional requirements. 2. Writing the test scenarios( what to check on the functionality - there are different check points) 3. Developing test cases(how to check the functionality detailing about the functional validation) 4. Test Execution(validation on the implemented product/ application to check whether the application functionality is meeting the requirement or not) 5. Defect management- how to manage the bugs or defects 6. Test Execution plan( Responsible by Test leads or managers) Tea - display 1. Full cup of tea 2. Half cup of tea 3. Hot water Product is : Tea vending machine 1. button size , color and position. 2. Display button is working or not 3. Button is working or not 4. button 1 is delivering full tea or not 5. button 2 is delivering half cup of tea or not 6. button 3 is delivering hot water or not 7. Any error is displaying or not in the console. 8. Taste of the tea 9. Time limit 10. Check for logos as per the document. 11. power supply is working or not 12. Ease of use. Example 2: we have a pen newly developed Check Points: 1. shape of the pen 2. color vs ink 3. as per the document which kind of pen-single side or both sides 4. usability of the pen 5. refill possibility 6. comfort grip 7. smoothness 8. Material of the pen as per the document 9. overflow of the ink 10. Durability 11. cap or button Sample Login page: 1. Background color 2. login button is clickable or not 3. aesthetics of login button 4. text boxes are working or not 5. mandatory fields like username or password 6. any messages regarding invalid username or password 7. invisibility of the password 8. minimize button and close button is working or not 9. password strength points 10. locking period 11. any messages or popup when username is blank 12. Reset button 13. Forgot password 14. Help button 15. Registration button Sample login page: 1.username and password case sensitive 2.Options dropdown working or not 3.Autologin and other options are working or not 4.valid login 5.invalid login 6.Reset button checking 7.Forgot password 8.Register 9.Closing login 10.password strength in registration 11.user friendly or not 12. compatibility in multi browser 13.Session management 14.performance - JMeter 15. load(scalability) 16. security testing Test plan: what is test, what we are going to test and what is the strategy to follow. what kinds of testing. Scope: what to test and what not to test. Test strategy: what kind of testing Roles and Responsibilities: Test engineer, test lead, project manager, review Test schedule : when to test, date and timelines Test deliverables: Each and every time delivering one document, test case document, test scenarios. Entry and Exit criteria: when to start and when to stop Suspension and Resumption criteria: when to stop if any show stopper is there and again when to start Tools : bug tracking tools and automation tools Risks: any risks and what is the mitigation plan Approvals: who will approve test cases. use case : Requirement understanding is it clear-- created by product owner. 1. paragraph 2. image, picture--- pictures are more clear Writing Test Scenarios ======================= 1.Understanding the functional requirements 2.How to write the test scenarios for the requirements Example : Login page (Facebook) Test scenarios: High level functionality 1.Verify user is able to login with valid user credentials. 2.verify user is able to create new account by using 'create new account' button. 3.verify user is able to reset the password by using forgotten password option/link. 4.verify user is able to create a page for celebrity, brand or business 5.Verify system should throw an error message when user is trying to login with invalid credentials. All account details will be there in FRS document given by product owner. we need to understand the functional requirements and convert into test scenarios. 6.Verify user is able to add account by clicking on add account thumbnail. 7.verify when user clicks on Recent Login thumbnail system should display login page for recent thumbnail. 8.Verify when user clicks on close icon in Recent login thumbnail recent login should remove from that page. 9.verify login page UI is as per UI standards(Alignments/Font Size/color theme etc) 10.verify login functionality with huge user load(Ex: There are 1000 users already logged in to the system and try to login as an end user and check the response time) 11.Verify the password visibility functionality. 12.Verify user can be able to login with their localized characters. 13.verify multi browser testing. What is Test scenario: A test scenario is high level description/check point to validate certain functionality. Epic/Feature: Login page implementation. user story: As a end user i should be able to login with valid user credentials. Acceptance criteria: 1. the end user can able to login by using Email or phone number. 2.login should allow only when end user enters valid email/ valid phone number and valid password. 3.Once login is successful then Facebook Home Page should display. Product owner/Business analyst will write the EPIC and User Stories(product backlog). Testing Types: 1.Functional Testing. 2.Non Functional Testing: user interface(UI) testing, font size, alignment, thumbnail, spelling mistakes Along with Functional Requirement specification(FRS) we can also have user interface specification(UI Specs) Mockup screens will be created by the UX team(user experience team). Testing Types: 1.Functional Testing 2.Non functional testing user interface(UI) testing usability testing Performance testing(JMeter/Hp-load runner/Hp performance center) Load testing stress testing. compatibility testing(Ex Multi browser support) Security testing Internationalization Testing localization testing Scalability of the application Eg: Big sale days by amazon/flipchart/Myntra etc. How much user load my application can tolerate Test Case Writing ================= previous class how to write test scenarios -- what to check on the functionality what is test case: A test case will contain clear steps of executing the functionality Steps will navigate starting from root location to the specific functional point Test case will describe how to execute the functionality which is the smallest part of the functionality. Ex: TS-1 :Verify user is able to login with valid user credentials. TC-1 :Verify user is able to login with valid username and valid password. Steps: ------ 1.open browser 2.launch the application 3.Enter valid username 4.Enter valid password 5.click on login button Expected result: login should success home page should display to the user. Test Data: input-1 : admin/master input-2 : admin-2024/master#123 input-3 : admin/master#1234 input-4 : admin123/master input-5: admin/blank password input-6 : blank username/blank password input-7 : blank username/correct password input-8 : username-max-char/password-max-char input-9 : username-min-char/password-min-char priority :P1(High priority) - login is always a high priority Module : Login Actual Result : Home page should be displayed Status : PASS/FAIL comments : where comments has to be there Test scenarios vs Test cases Here is the user story(functional requirement) assigned to you now the question is how much time you need to write the test cases for the user story Points to remember: 1. From each test scenario: we can derive min 3 testcases Ex: you have 10 test scenarios 10Ts--> 10Ts*3 -- 30 test cases will come approximately 2.How many test cases can be executed on average per day by a QA Engineer Ex: 10 to 15 testcases a QA Engineer can complete in a day. Lets stick to 15 testcases. 3. How many testcases can be written in a day? Ex: 10 to 15 test cases per day(10 test cases i can write per day) ----30/10--3 days JIRA Introduction ================== JIRA is test management tool jira is basically used for project execution tracking tool. It has some plugins x-ray. Product backlog-- is the place we can keep our functional requirements. EPIC- a feature or a major business requirement -- Product owner/BA EPIC can be breakdown in to multiple user stories. user story is a small sized functional requirement which can be completed within a sprint. user stories will be there in the product backlog Sprint planning we will pickup some user stories --- us001,us002,us003,us004 In one sprint planning we will complete us001,us002,us003 us004 is not completed then this user story will be sprint backlog. whatever we commit in the sprint not able to complete the user story then it is called sprint backlog. story point == 1hour/1day Steps: Select Jira service mgt Give name invite team members select scrum 1.How to create project in JIRA Backlog -->EPIC-->stories Create sprint --Add stories to the sprint--start sprint--add tasks for every story first we need to create an epic in the backlog Multiple stories are created create sprint in the Jira adding user story points to the sprint starting the sprint Defect Management =================================================== key QA responsibilities in the JOB 1-understanding the functional requirements/user stories 2-Test Scenarios(what to check) 3-Test cases(How to check the functionality) 4-Test execution phase 5-Defect Management ----------->what is defect/bug ----------->What is the defect/bug life cycle ----------->what all different components in bug ------------------------------------------------------- Example of Different Defects. Defect-1:When user clicks on logout link, the application is not able to logout impact: consider a scenario you are using public computer(Net center/Airport Lounge) --------------->you opened your Gmail application --------------->then you sent a mail --------------->and then you click on logout Actual result: Logout is not working, that means , you are not able to logout from Gmail. Another Ex: you are trying to transfer money from your net banking and here is incase logout is not working. ------------------------------------------------------------------------------------------- How to log a Defect: Defect ID: incase any tool(like JIRA-Xray) Defect Title: when user clicks on logout link, the application is not able to logout. Reproduction steps: Steps: 1-Open the Browser and Launch the application 2-Login as a valid user 3-click on logout. Actual Result: user is unable to logout. Expected Result : user should be logged out. Attachments: screenshots/log files Priority: Refers how urgent this problem to fix it...(P1/P2..P4) -------------->The priority value can be dynamic. Severity: Refers the impact of the problem(It show case Importance of the fix ---s1/s2/s3.... --------------->The severity is static. Some consideration while choosing the priority: ex: If the defect is crashing the system/ or blocking the entire application then it will be P1. If the defect is blocking some major functionality then it will be classified as P2. If the defect is UI related or alignment related issues then it will be classified as P3. Assignee : Developer. API Testing ============== Postman tool we can perform api testing no need to have any coding language. We will give some URL it goes to the server and same data we get as a response. HTML code will be interpreted by the browser and will send the response. All web applications come under 3 tier architecture. 3-Tier-client tier, Business logic tier, Database tier Business logic layer will have programs depends on request corresponding business logic layer will be executed. Business logic layer acts as mediator between client and database. API testing depends on business logic layer. 3 tier architecture - internet came presentation layer - scripting language Application layer - programming language Presentation layer-- we perform user interface testing Business logic layer -- we perform API testing. Browser is just a presentation layer. In business logic layer we will do request and response testing. API is nothing but a collection of programs. API sending request and getting response. Pure API means we don't need any internet. Firs API is in QA environment where we call it as API's. After that we will keep it in production its called a webservice. All webservices are APIS but not all API's are webservices. GET(select) POST(create) PUT(update) DELETE(Delete) Postman use gmail account to maintain all files. URL : Unified Resource Locator--- Generally we perform testing by using different urls URI :Unified Resource identifier-- we perform API testing by using different uri's If URL contains everything then it's called URI. we will validate the response by using status code. How much time POSTMAN TOOL ============== URI: https://reqres.in/api/users?page=2 GET(select) POST -->Request body/Request payload PUT -->Request body/Request payload DELETE Every request will get you response in JSON format/HTML/XML/text etc For each test case we will write the validation part. 200 and 201 status codes are successful status codes. tests["Validating status code"] = responseCode.code == 200; tests["Validating response body"] = responseBody.has("michael.lawson@reqres.in"); var response = JSON.parse(responseBody); tests["Page no"] = response.page == 2; https://reqres.in/api/users After question mark login -- API--- username and password In servers data will be there. if the data is valid in the server then it will send a token. Get command: https://reqres.in/api/users?page=2 Get single user :https://reqres.in/api/users/2 post command: https://reqres.in/api/users Put command : https://dummy.restapiexample.com/api/v1/create