If you want to get started with testing, you must understand the software development process

In the software testing industry, the tested objects are software every day. If you want to complete the testing work better, you first need to have a basic understanding of the object under test, that is, the software.

software

Computer programs, possible files, documents and data related to the operation of the computer system.

The program is easy to understand, and it is a product that can be operated. For example, wps, WeChat, QQ, web pages, etc. are all programs. For example, requirements documents, design documents, and user manuals are all documents. What is displayed on the page, as well as the content entered by the user, are all data.

Therefore, the combination of programs, documents, and data is a complete software.

Evolution of the software development process

The evolution of the process is actually the evolution of the software development model.

The software development model is that in software development, a lot of experience is gradually summed up, and these experiences become a development model after refining and summarizing. For example, the waterfall model at the beginning, later came to the agile development model, and has been developed to the most popular DevOps model.

Next, introduce these development models respectively.

traditional waterfall model

Everyone is familiar with waterfalls, the water flows down from top to bottom. The same is true for the waterfall model, which proceeds step by step from top to bottom like water flow.

insert image description here
demand analysis

No matter what you do, the work of analysis is definitely essential. The same is true in the waterfall model. The first thing to do is demand analysis.

Requirements documents are learned and collected by product personnel from users. After understanding what the user wants, refine it into a document. The document will clearly list the general major function modules of the system, which small function modules the major function modules have, and also list the related interfaces and interface functions. With this document, the UI interface and functions of the product are determined.

design

After the requirements analysis, the design begins. The design needs to include two aspects:

Interface design: UI designers design a design draft of the front-end interface according to the requirements. Program design
: design the basic business process, how to divide modules, interface specifications, etc.
After the design is completed, developers can enter the coding stage.

coding

In the software coding stage, the development will implement these plans through code according to the designed plans.

accomplish

Realization means that the developed code has realized these functions in the requirements.

test

Once implemented, testers can step in. This is the process of the waterfall model, with the code, then do the test.

release maintenance

After the testing work is completed, it will be released and launched, and the product will continue to be maintained.

features

In the waterfall model, the various activities of software development are carried out strictly in a linear manner, the current activity accepts the work results of the previous activity, and the work results of the current activity need to be verified.

The waterfall model is a type of linear model. It occupies an important position among all development models and is a foundation for all other models. Other models are evolved from this linear model.

The advantages of the waterfall model are obvious. The various stages of development are relatively clear, emphasizing early planning and demand investigation, and are more suitable for product development with stable demand.

But because the development model is linear, which increases the risk of development, early errors may not be discovered until later stages of development.

In order to solve these problems in the waterfall model, other development models were gradually developed later.

agile development model

Agile development mode is a new software development method that has gradually attracted widespread attention since the 1990s. This development model is more suitable for scenarios where requirements change frequently and rapid development is required.

The common agile development models are XP and Scrum. The following two development models are introduced respectively.

XP Extreme Programming

XP (eXtreme Programming) is a near-spiral development method. It breaks down the complex development process into relatively simple small cycles. In each cycle, project personnel and customers can be very clear about the development progress, changes, problems to be solved and potential difficulties, etc., and can adjust the development process in a timely manner according to the actual situation.
insert image description here

As can be seen from the figure above, Extreme Programming organizes the development process from three dimensions.

programming method

The first is the dimension of programming method. In this latitude, the developer's development method is stipulated.

Simple design: XP requires the simplest way to achieve each small requirement. As long as these designs can meet the current needs of customers, there is no need to make more advanced designs. These designs will be continuously adjusted and optimized in the subsequent development process.

Pair programming: When code is written by two people together. One mainly thinks about coding details. The other person mainly focuses on the overall structure, constantly reviewing the code written by the first development.

Test-driven development: The basic idea of ​​test-driven development is to write test code before developing functional code. After the test code is written, write the functional code that can pass the test code. This allows tests to drive the entire development process. Doing so helps to write concise, usable and high-quality code with high flexibility and robustness.

Refactoring: XP emphasizes simple design, but simple design does not represent flow without any structure, nor does it mean program design that lacks reusability. XP advocates refactoring code, mainly to reduce the recurring parts of programs and designs and enhance the reusability of programs and designs.

group practice

Group practice is to specify working methods from the dimension of teamwork.

Collective code ownership: Code ownership means that everyone is responsible for all code. This in turn means that everyone can change any part of the code.

Coding standards: Because everyone can change the code, everyone in the development team needs to follow a unified programming standard. This way all the code looks as if it was written by one person. Because of a unified programming specification, it is easier for each programmer to understand the code written by others, which is one of the important prerequisites for collective code ownership.

Steady and high-speed pace: The team can only hope to win if it persists. Think of the project as a marathon rather than a sprint. Team members are required to maintain a long-term and stable work rhythm.

Continuous integration: Integration is to merge everyone's code together. Team development members need to integrate their work frequently. Each integration is verified by automated builds (which also includes automated tests), so that integration errors can be found as quickly as possible.

Metaphors: In order to help everyone clearly understand the customer needs to be fulfilled and the system functions to be developed, the team needs to use many metaphors to describe how the system or functional modules work. For example, for a search engine, the system metaphor might be "a swarm of spiders that prowl the web looking for something to catch and bring it home."

Delivery and Management

The last one is the dimension of release management. Delivery is putting the product in the hands of the customer. Launching is putting the product online and making it accessible to users. In general, delivery and release are about making the product available to users for use.

Small releases: How small is that? That's 1-3 weeks per iteration. At the end of each iteration, the team delivers working, tested functionality that is ready for immediate use.

The planning game: predict how much work can be done by the delivery date, and determine what to do now and next. Constantly answering these two questions is directly serving how to implement and adjust the development process.

Complete Team: Every project contributor is an integral part of the "team". The team is built around a commercial representative who sits and works with the team every day - the "customer".

On-site customer: In XP, the "customer" is not the person who pays the bill for the system, but the person who actually uses the system. XP believes that customers should always be there to solve problems.

It can be seen from the XP development model that development and customers are dominant. The work of testing is basically carried out through automation. For example, test-driven development in the coding process, and continuous integration also includes automated testing. Generally speaking, this development model has very high requirements for development and testing. The people in the team must have a very high level, so that this model can operate successfully. This is an ideal situation for developing small projects, which is more difficult to achieve.

SCRUM

In the Scrum model, the most basic concept is Sprint. Sprint is actually a sprint, and in layman's terms it is an iterative cycle.
insert image description here

Before the entire project starts, there will be a product Backlog. Use the Product Backlog to manage product requirements. It is a summary document for the entire project. Backlog is a list of requirements sorted by business value, and the list items are usually reflected in the form of user stories.

The Scrum Team picks the highest priority requirements from the Product Backlog for development. Selected requirements are discussed in the Sprint Planning meeting.

After discussion, analysis and estimation on Sprint, the corresponding task list can be called Sprint Backlog.

In Scrum, the entire development process consists of several short iteration cycles, a short iteration cycle is called a Sprint, and the recommended length of each Sprint is two to four weeks.

During each iteration, the Scrum Team holds a daily standup. Review progress against the Sprint Goal at the daily standup and make adjustments to optimize the next day's work.

At the end of each iteration, the Scrum Team delivers a potentially shippable product increment.

At the end of each iteration, a Sprint Review meeting is required to allow the team to present the completed functionality to the Product Owner and stakeholders.

After the Sprint Review meeting and before the next Sprint Planning meeting, a Sprint Retrospective meeting is required. The retrospective meeting is to find out what went well and what didn't go well during the Sprint, and what improvements the team can make.

This is the workflow of the entire SCRUM model. In each Sprint, that is, an iteration cycle, it is actually a small waterfall. In each iteration cycle, a complete process from requirements analysis-design-coding-testing-online will be completed. Different iteration cycles may partially overlap. For example, the first iteration cycle has reached the testing stage, and the requirements analysis of the second iteration cycle may have already started. This non-stop loop iteration proceeds downward.

DevOps development model

DevOps (a portmanteau of Development and Operations), which involves software at all stages of its development lifecycle.

DevOps is a development model that pays great attention to the communication and cooperation between development (Dev), operation and maintenance (Ops), and testers.

In DevOps, the automated software delivery process is used to make building, testing, and releasing software faster, more frequent, and more reliable.

Its appearance is actually because the current software needs to be launched more quickly, if you want to achieve new functions that can be launched every day. But the agile development model, no matter how fast it takes a week, cannot meet this requirement. So everyone realized that in order to go online more quickly, development, testing, and operation and maintenance must work closely together. Therefore, DevOps is more suitable for use in scenarios where requirements change frequently, and development, testing, and operation and maintenance require agility.

insert image description here
DevOps life cycle

Let's take a look at what stages are included in the DevOps model.

continuous development

This is the phase of continuous software development in the DevOps lifecycle. Unlike the waterfall model, software deliverables are decomposed into multiple task nodes with short development cycles, developed and delivered in a very short period of time.

This phase includes planning, coding and building phases

Planning phase: You can use some project management tools, such as JIRA to manage the entire project
Coding phase: You can use Git or SVN to maintain different versions of code
Construction phase: Use packaging tools, such as Maven tools, to package the code into executable files

continuous testing

In this phase, the developed software is continuously tested.

For continuous testing, you can use some automated testing tools, such as Selenium and Appium. Selenium is a tool for web automation, and Appium is a tool for app automation. Automated tools also need to be used together with testing frameworks, such as TestNG and JUnit in Java, unittest and pytest in python. With these automated testing tools, the developed software can be continuously tested.

At this stage, it is also very convenient to use Docker containers to simulate a "test environment" in real time.

Continuous Integration (CI)

Once new code submissions pass the tests, they are continuously integrated with existing code. This is the process of continuous integration.

At this time, you can use Jenkins, which is the most popular continuous integration tool. Using Jenkins, the latest code can be pulled from a Git repository and produce a build that can eventually be deployed to a test or production server.

You can also set Jenkins to automatically trigger a new build when it finds a newly committed code in the Git repository, or you can manually trigger a new build when you click a button. With the tool of Jenkins, continuous integration can be done very conveniently.

continuous deployment

After the continuous integration is completed, the code can be directly deployed to various environments. At this stage, it is necessary to ensure that only correct code that has passed continuous testing can be deployed to the server.

Because if new features are launched, more users will use the product. In this case, the operation and maintenance personnel may also need to expand the server to accommodate more users. If continuous deployment is possible, deployment tasks can be performed quickly and frequently through configuration management tools. Let the product meet the user faster. This opens up a fast track from development, testing to launch.

At this stage, the containerization tool Docker also plays an important role. It can help keep various environments consistent. For example, test environment, production environment, etc., because different environments may also cause some bugs to appear.

continuous monitoring

After the deployment goes online, it comes to the stage of continuous monitoring. This is a very critical stage in the DevOps life cycle. Online monitoring can help improve software quality and monitor software performance.

This will also involve the participation of the operation team, who will also monitor some erroneous behaviors of users in the process of using the product, and provide data support for further optimization of future requirements.

At this stage, the ELK Stack can be used. This is a platform for collecting online data and analyzing and displaying it. This tool can automatically collect user actions and some online bad cases of the product. By analyzing these data, it can guide the future development direction of the product.

The above content is the entire life cycle of DevOps.


              [The following is the most complete software test engineer learning knowledge architecture system diagram in 2023 that I compiled]


1. From entry to mastery of Python programming

2. Interface automation project actual combat 

3. Actual Combat of Web Automation Project


4. Actual Combat of App Automation Project 

5. Resume of first-tier manufacturers


6. Test and develop DevOps system 

7. Commonly used automated testing tools

Eight, JMeter performance test 

9. Summary (little surprise at the end)

life is long so add oil. Every effort will not be let down, as long as you persevere, there will be rewards in the end. Cherish your time and pursue your dreams. Don't forget the original intention, forge ahead. Your future is in your hands!

Life is short, time is precious, we cannot predict what will happen in the future, but we can grasp the present moment. Cherish every day and work hard to make yourself stronger and better. Firm belief, persistent pursuit, success will eventually belong to you!

Only by constantly challenging yourself can you constantly surpass yourself. Persist in pursuing your dreams and move forward bravely, and you will find that the process of struggle is so beautiful and worthwhile. Believe in yourself, you can do it! 

Guess you like

Origin blog.csdn.net/nhb687095/article/details/131994510