5.1 Ase
5.1 Ase
• Build and deployment automation, Learn to use Ansible for configuration management.
• Test automation (as part of continuous integration), Learn to set up test automation
cases using Robot Framework.
1. Glenford J. Myers, et. al., The Art of Software Testing, Wiley.
• Your configuration management strategy will determine how you manage all
of the changes that happen within your project.
• In Software Engineering, Software Configuration
Management(SCM) is a process to systematically manage, organize,
and control the changes in the documents, codes, and other entities
during the Software Development Life Cycle.
test, and release process- We tackle this in two parts: getting everything into
• Everything you need to build, deploy, test, and release your application should be kept in some
• This includes requirement documents, test scripts, automated test cases, network configuration
scripts, deployment scripts, database creation, upgrade, downgrade, and initialization scripts,
application stack configuration scripts, libraries, toolchains, technical documentation, and so on.
• All of this stuff should be version-controlled, and the relevant version should be identifiable for
• That is, these change sets should have a single identifier, such as a build number or a version
• The aim of a version control system is twofold: First, it retains, and provides
access to, every version of every file that has ever been stored in it. Second,
it allows teams that may be distributed across space and time to collaborate.
Keep Absolutely Everything in Version Control :-
• The objective is to have everything that can possibly change at any point in
the life of the project stored in a controlled manner.
• This allows you to recover an exact snapshot of the state of the entire
system, from development environment to production environment, at any
point in the project’s history.
• It is even helpful to keep the configuration files for the development team’s
development environments in version control since it makes it easy for
everyone on the team to use the same settings.
• Analysts should store requirements documents.
• Testers should keep their test scripts and procedures in version control.
• Project managers should save their release plans, progress charts, and risk
logs here.
• In short, every member of the team should store any document or file
related to the project in version control.
Check In Regularly to Trunk:-
• it is important to be sure that your work, whatever it may be, is ready for the level of publicity that
a check-in implies.
• When a new features is developed incrementally, commit them to the trunk in version control on a
regular and frequent basis.
• It means that your software is always tested because your automated tests are run on trunk by the
continuous integration (CI) server every time you check in.
• It reduces the possibility of large merge conflicts caused by refactoring, ensures that integration
problems are caught immediately when they are cheap to fix, and results in higher-quality
software.
Use Meaningful Commit Messages:-
• Every version control system has the facility to add a description to your commit.
• It is easy to omit these messages, and many people get into the bad habit of doing
so.
• The most important reason to write descriptive commit messages is so that, when
the build breaks, you know who broke the build and why.
• A commit message explaining what the person was doing when they committed
that change can save you hours of debugging.
Managing Dependencies
• The most common external dependencies within your application are the
third party libraries it uses and the relationships between components or
modules under development by other teams within your organization.
• we emphasize that your build system should always specify the exact version
of the external libraries that you use.
• Whether you keep external libraries in version control or not involves some
trade-offs. It makes it much easier to correlate versions of your software with
the versions of the libraries that were used to build them.
Managing Software Configuration
• Configuration is one of the three key parts that comprise an application, along with its binaries and
its data.
• Configuration information can be used to change the behavior of software at build time, deploy time,
• Delivery teams need to consider carefully what configuration options should be available, how to
manage them throughout the application’s life, and how to ensure that configuration is managed
• you should treat the configuration of your system in the same way you treat your code: Make it
• Most applications they are designed for a specific purpose, but within the bounds of
that purpose they will usually have some ways in which their behavior can be
modified.
• The desire to achieve flexibility may lead to the common antipattern of “ultimate
configurability” which is, all too frequently, stated as a requirement for software
projects.
• It is at best unhelpful, and at worst, this one requirement can kill a project.
• Configurable software is not always the cheaper solution it appears to be. It’s
little configuration and then add configuration options later when necessary.
consistently.
• Deployment smoke tests are one way to mitigate this problem and should
always be used.
• Smoke tests are a subset of test cases that cover the most important
functionality of a component or system, used to aid assessment of whether
main functions of the software appear to work correctly. Smoke testing is also
done by testers before accepting a build for further testing.
• Whatever mechanism you choose, it is recommended that, as far as practically
possible, you should try and supply all configuration information for all the
applications and environments in your organization through the same
mechanism.
• This isn’t always possible, but when it is, it means that there is a single source
of configuration to change, manage, version-control, and override (if
necessary).
• The principle to bear in mind when managing the environment that your application
runs in is that the configuration of that environment is as important as the configuration
of the application.
• For example, if your application depends on a messaging bus, the bus needs to be
configured correctly or the application will not work.
• The problems can be summed up as follows:
1. One small change can break the whole application or severely degrade its
performance.
2. Once it is broken, finding the problem and fixing it takes an indeterminate amount
of time and requires senior personnel.
2. Fixing one of your environments can take many hours. It is always better to be able
to rebuild it in a predictable amount of time so as to get back to a known good state.
1. The various operating systems in your environment, including their versions, patch
levels, and configuration settings.
4. Any external services that your application depends upon, including their versions
and configuration.
5. Any data or other state that is present in them (for example, production databases)
• There are two principles that form the basis of an effective configuration
management strategy:
• Applying these fundamentals to every part of your system will pave the way
to the point where creating new environments, upgrading parts of your
system, and rolling out new configurations without making your system
unavailable becomes a simple, automated process.
• When evaluating third-party products and services, start by asking
the following questions:
• Any time you change any aspect of the host environment of your applications, you
should store the change, creating a new version of the baseline and associating that
version of the application with the new version of the baseline.
• This ensures that the next time that you deploy the application or create a new
environment, it will include the change.
• You should treat your environment the same way you treat your code—changing it
• Every change should be tested to ensure that it doesn’t break any of the applications
• If this is true on your project, integrate every time somebody checks in, and do it from
• If testing is a painful process that occurs just before release, don’t do it at the end.
4. Facilitating automation