ISTQB FOUNDATION 4.0 | Tutorial 42 | Acceptance Test Driven Development | Test Design Techniques

TM SQUARE
13 Feb 202410:11

Summary

TLDRThis tutorial delves into Acceptance Test-Driven Development (ATDD), an agile approach where test cases are collaboratively written before development, based on acceptance criteria. It emphasizes a test-first methodology involving multi-stakeholder perspectives to ensure clarity and correctness. The script outlines steps including a specification workshop, test case creation, and iterative development to pass the tests, highlighting the importance of clear, non-redundant test cases that serve as executable requirements for developers.

Takeaways

  • 📘 ATDD stands for Acceptance Test Driven Development and is a collaborative approach used in Agile methodologies.
  • 🔍 ATDD involves writing test cases based on acceptance criteria before the actual development begins, emphasizing a test-first approach.
  • 👥 The test cases in ATDD are created by a team with diverse perspectives including customers, developers, and testers.
  • 🛠 Test cases may be executed either manually or automated, offering flexibility in the testing process.
  • 📝 The Specification Workshop is a key step where user stories and acceptance criteria are analyzed and ambiguities are resolved.
  • 📈 ATDD helps in ensuring the implementation meets the requirements by using test cases as a reference for developers.
  • 📝 Test cases should be written clearly and understandably to be accessible to all stakeholders, including those who might need to reproduce defects.
  • 🚫 The script emphasizes avoiding duplicate test cases to prevent redundancy and ensure each test case covers unique aspects of the user story.
  • 🔄 Developers work in a tight loop of refactoring and rerunning tests until they pass, indicating successful implementation.
  • 📋 Once tests pass, they serve as executable requirements for the feature, providing a clear and agreed-upon standard for implementation.
  • 🌟 The tutorial highlights the importance of writing detailed yet specific test cases that cover all characteristics of the user story without unnecessary details.

Q & A

  • What is the main focus of Chapter 4 in the ISTQB Foundation Level certification tutorial?

    -The main focus of Chapter 4 is on test analysis and design, specifically discussing collaboration-based test approaches, including Acceptance Test Driven Development (ATDD), Test Driven Development (TDD), and Behavior Driven Development (BDD).

  • What does ATDD stand for and what is its significance in Agile methodologies?

    -ATDD stands for Acceptance Test Driven Development. It is significant in Agile methodologies as it is a collaborative approach where test cases are written based on acceptance criteria before the actual development, ensuring that the implementation meets the specified requirements.

  • What are the three standard test approaches used in Agile?

    -The three standard test approaches used in Agile are Test Driven Development (TDD), Behavior Driven Development (BDD), and Acceptance Test Driven Development (ATDD).

  • Why is it important for test cases to be created prior to the implementation of a story in ATDD?

    -Creating test cases prior to implementation in ATDD is important because it ensures that the development is guided by the acceptance criteria, helping to identify and resolve any ambiguities or defects in the user stories, and ultimately leading to more accurate and efficient implementation.

  • What is the role of a specification workshop in the context of ATDD?

    -A specification workshop is where the user story and its acceptance criteria are analyzed, discussed, and written by the team members. It helps resolve any incompleteness, ambiguities, or defects in the user stories and ensures that the test cases are based on a clear understanding of the requirements.

  • Can test cases in ATDD be executed manually or do they need to be automated?

    -Test cases in ATDD can be executed both manually and through automation. It is not a requirement for them to be automated; the choice depends on the specific needs and resources of the project.

  • What is the purpose of writing test cases first in the ATDD approach?

    -Writing test cases first in the ATDD approach serves as a reference for developers to understand the expected behavior of the software. It helps ensure that the implementation aligns with the acceptance criteria and that the final product meets the specified requirements.

  • How should test cases be written in the ATDD approach to ensure they are understandable for all stakeholders?

    -Test cases should be written in a way that is understandable for all stakeholders, using natural language that includes necessary preconditions, inputs, and postconditions. They should be detailed enough for anyone to reproduce the test or understand the rationale behind a failure.

  • What is the significance of not having duplicate test cases in the ATDD approach?

    -Avoiding duplicate test cases in the ATDD approach is important to prevent redundancy and ensure that each test case uniquely covers a specific aspect of the user story. This helps maintain clarity and efficiency in the testing process.

  • How do developers interact with test cases in the ATDD approach?

    -In the ATDD approach, developers work closely with the test cases, using them as a guide to implement the feature described by a user story. They may go through repeated iterations of running the tests, refactoring the code, and rerunning the tests until all tests pass, indicating that the implementation is complete.

  • What is the final outcome of the ATDD process in terms of the acceptance tests?

    -The final outcome of the ATDD process is that the acceptance tests become executable requirements for the implementation. They serve as a confirmation that the software meets the specified acceptance criteria and is ready for deployment.

Outlines

00:00

📚 Introduction to Acceptance Test Driven Development (ATDD)

This paragraph introduces the topic of Acceptance Test Driven Development (ATDD) within the context of agile methodologies. It explains that ATDD is a collaborative approach where test cases are written first based on acceptance criteria, before the actual development begins. The paragraph discusses the standard test methods in agile, namely TD, BDD, and ATDD, and highlights the importance of a specification workshop where team members analyze and define acceptance criteria. The summary emphasizes the test-first approach of ATDD, where test cases are created by a diverse team including customers, developers, and testers, and may be executed manually or through automation.

05:01

🔍 In-Depth Exploration of ATDD Test Case Writing

The second paragraph delves deeper into the specifics of writing test cases in ATDD. It outlines the process starting with positive test cases using valid data to ensure the 'happy path' is correctly tested. The paragraph then discusses the importance of negative testing to confirm correct behavior under error conditions and the inclusion of non-functional quality characteristics such as performance and usability. The summary stresses the need for test cases to be understandable to stakeholders and to cover all aspects of the user story without duplication. It also touches on the iterative process between developers and testers, where tests are run, code is refactored, and tests are rerun until they pass, signifying successful implementation.

10:03

🎓 Conclusion and Encouragement for Continuous Learning

The final paragraph serves as a conclusion to the tutorial, encouraging viewers to continue learning and exploring the subject matter. It emphasizes the importance of understanding the context and provides an open invitation for viewers to ask questions or comment for further clarification. The paragraph ends with a motivational note to keep learning and a sign-off with a cheerful tone, indicating the end of the video tutorial.

Mindmap

Keywords

💡ISTQB Foundation Level Certification

ISTQB Foundation Level Certification is a globally recognized qualification for software testers. It signifies that the individual has a foundational understanding of software testing principles and practices. In the video, the tutorial is focused on this certification, specifically discussing test analysis and design in the context of agile methodologies.

💡Test Analysis and Design

Test Analysis and Design is a process within software testing that involves understanding the requirements and designing test cases to ensure the software meets those requirements. The video script discusses this as part of Chapter 4, emphasizing its importance in the ISTQB certification and its application in agile environments.

💡Acceptance Test Driven Development (ATDD)

Acceptance Test Driven Development (ATDD) is an agile software development approach where acceptance tests are written collaboratively before the actual coding begins. The script explains ATDD as a test-first approach, highlighting its significance in ensuring the software meets the defined acceptance criteria.

💡Test Driven Development (TDD)

Test Driven Development (TDD) is a software development technique where tests are written before the code that is supposed to pass those tests. In the script, TDD is mentioned as one of the three standard test methods or approaches in agile, alongside BDD and ATDD.

💡Behavior Driven Development (BDD)

Behavior Driven Development (BDD) is a software development approach that focuses on the behavior of software from the user's perspective. The script refers to BDD as having been discussed in Chapter 2, indicating its relevance in the context of agile methodologies.

💡Collaborative Approach

A collaborative approach in the script refers to the involvement of multiple stakeholders, such as business analysts, developers, and testers, in the process of writing test cases. This approach is integral to ATDD, ensuring that tests are comprehensive and reflect the perspectives of all involved parties.

💡Acceptance Criteria

Acceptance Criteria are conditions that must be met for a feature to be considered complete and acceptable from a user's perspective. The script discusses how test cases in ATDD are derived directly from these criteria, emphasizing their importance in guiding the development process.

💡Specification Workshop

A Specification Workshop, as mentioned in the script, is a collaborative session where team members analyze, discuss, and define acceptance criteria for user stories. It is a key step in the ATDD process, ensuring clarity and completeness of requirements before test case creation.

💡Test Cases

Test Cases are detailed descriptions of the steps required to test a particular feature or functionality of the software. The script explains that in ATDD, test cases are created before development and are based on acceptance criteria, serving as the basis for implementation.

💡Positive and Negative Testing

Positive testing involves testing the software with valid input to ensure it performs as expected, while negative testing checks the software's response to invalid or unexpected input. The script mentions that after creating positive test cases, the team should perform negative testing to cover all possible scenarios.

💡Non-functional Quality Characteristics

Non-functional Quality Characteristics refer to attributes of software that are not directly related to the functionality but impact the overall quality, such as performance, efficiency, and usability. The script points out that test cases should also cover these characteristics to ensure comprehensive testing.

💡Executable Requirements

Executable Requirements are test cases that can be run automatically to verify the software's behavior against the specified requirements. The script explains that in ATDD, acceptance tests serve as executable requirements, guiding the development process and confirming the implementation's correctness.

Highlights

Introduction to ISTQB Foundation Level Certification Chapter 4 on Test Analysis and Design.

Discussion on Collaboration Based Test Approaches, specifically Acceptance Test Driven Development (ATDD).

Explanation of the three standard test methods in Agile: TDD, BDD, and ATDD.

ATDD is a collaborative approach to writing test cases from acceptance criteria.

Test cases in ATDD are written before development, emphasizing a test-first approach.

Involvement of different team members including customers, developers, and testers in creating test cases.

Test cases may be executed manually or automated in ATDD.

The Specification Workshop process for analyzing and writing acceptance criteria.

Importance of resolving incompleteness and ambiguities in user stories during the workshop.

Creating test cases based on acceptance criteria as examples of software functionality.

The rationale behind writing tests first to guide development and ensure implementation meets requirements.

Interchangeable use of the terms 'test' and 'examples' in Agile methodology.

Application of test techniques in Agile based on detailed requirement information.

The sequence of writing test cases in ATDD: starting with positive test cases, followed by negative testing, and non-functional characteristics.

Test cases should be understandable to stakeholders and contain necessary preconditions, inputs, and postconditions.

Ensuring test cases are specific to the user story and avoiding unnecessary aspects.

Uniqueness of test cases to prevent duplication and ensure each test covers different characteristics.

Developers automate test cases by writing supporting code while implementing features.

The iterative process of running, refactoring, and rerunning tests until they pass, indicating successful implementation.

Acceptance tests serve as executable requirements for the implementation.

Emphasis on the efficiency and collaborative review of test cases during their creation.

Closing remarks encouraging continuous learning and exploration in the context of Agile testing.

Transcripts

play00:00

Hello friends and greetings for today

play00:02

welcome back to another tutorial on

play00:03

istqb Foundation level certification we

play00:06

are in chapter 4 talking about test

play00:08

analysis and design and continuing ahead

play00:10

with our same segment that is 4.5

play00:13

collaboration based test approaches and

play00:16

as a part of today's tutorial we'll be

play00:18

getting into the discussions of what is

play00:21

acceptance test driven

play00:28

development

play00:33

when it comes to the test approaches

play00:34

being used in agile we have three

play00:36

standard test methods or approaches and

play00:38

that are called as tddd bdd and atdd TD

play00:43

stands for test driven development bdd

play00:46

stands for Behavior driven development

play00:48

which we have discussed in Chapter 2

play00:49

already and now we have time to talk

play00:51

about the third one which is acceptance

play00:53

trust driven development however

play00:55

acceptance test is a collaborative

play00:57

approach of writing test cases right

play00:59

from acceptance criterias and thus it

play01:02

becomes one of the techniques in order

play01:04

to analyze the information at the same

play01:06

way design the appropriate test cases

play01:09

the only difference here is that the

play01:11

test are written first then the

play01:14

development so test cases are DED right

play01:16

from acceptance criteria and then based

play01:19

on these tests the development will be

play01:21

done by the developers so let's quickly

play01:23

have a look and try to understand what

play01:25

exactly this particular topic is trying

play01:27

to convey us from the syllabus the first

play01:30

and foremost important thing is ATD is a

play01:32

test first approach the test cases are

play01:34

created prior to implementation of the

play01:37

story the test cases are created by team

play01:40

members with different perspective which

play01:43

includes customer developers and testers

play01:46

so and anyways as I just told you that

play01:49

it is a collaborative approach of

play01:50

writing these test cases so it does not

play01:52

just include a business analyst or

play01:55

product owner to only alone write the

play01:57

test cases however it's a collaborative

play01:59

approach so it includes includes the

play02:00

perspective of the business developers

play02:02

and testers put together in order to

play02:04

derive the test cases right from the

play02:06

acceptance criteria also to add here uh

play02:09

the test cases may be executed manually

play02:11

or automated so it's not necessary that

play02:13

it should only be automated but it can

play02:15

be executed manually as well now the

play02:17

four step is of course is the

play02:19

specification Workshop where the user

play02:22

story and that is if not yet defined its

play02:25

acceptance criteria are analyzed

play02:28

discussed and written by the team

play02:30

members incompleteness ambiguities or

play02:34

defects in the user stories are resolved

play02:36

during this process so I think that's a

play02:38

very common and straightforward thing at

play02:40

this point of time after covering

play02:41

chapter 3 also where we told you about

play02:43

that the review processes helps you to

play02:45

identify the anomalies in the written

play02:47

work product so at this point of time if

play02:50

you have the user stories written even

play02:52

if you don't have acceptance criteria

play02:53

the team sits together in order to

play02:55

discuss analyze and find ambiguities

play02:57

related to user stories and then look

play03:00

forward to derive the test cases but

play03:02

prior to that of course the test bases

play03:04

completeness and correctness has to be

play03:06

measured and that certainly gets done

play03:08

right at this point of time also to add

play03:11

here when it comes to the next step it

play03:13

is to create the test cases this can be

play03:15

done by the team as a whole or by the

play03:18

tester individually as well the test

play03:20

cases are based on acceptance criteria

play03:23

and can be seen as examples of how the

play03:25

software works this will help the team

play03:28

implement the user stories correctly so

play03:31

one way it's more of like the concept of

play03:34

test methods however discussed in agile

play03:37

very detailed but right here all I we

play03:39

want to let you know in a very crisp

play03:41

manner that why should we write test

play03:43

before development the more important

play03:46

thing here is to understand that when it

play03:48

is a test which justifies whether the

play03:50

implementation is up to the mark Or Not

play03:52

the question is why don't we write the

play03:54

test first so if the test is written

play03:56

first then certainly it will do the

play03:58

Fulfillment of of what the

play04:00

implementation has to be and the

play04:01

developer has to stick to that

play04:03

particular reference that what the test

play04:05

cases are trying to say and based on

play04:07

that I can look forward to continue

play04:09

further in terms of what exactly to

play04:11

implement so that the test cases passes

play04:14

so of course at the end the test should

play04:16

pass in order to say the implementation

play04:18

is accomplished so we just give the test

play04:21

initially before the development to the

play04:24

U team in order to say let's go ahead

play04:27

and implement it according to that so

play04:30

let's add further and right here the

play04:31

since examples and tests are the same

play04:34

these terms are often used

play04:37

interchangeably which means uh the test

play04:40

and examples are exactly the same thing

play04:43

so these are common keywords which are

play04:44

used quite often as a part of the agile

play04:48

methodology and they are quite often

play04:51

easily interchangeable in terms of

play04:53

utilization also to add here during the

play04:55

test design the test techniques may be

play04:57

applied so it's not that when it comes

play04:58

to Agile the the test techniques are

play05:00

restricted the test techniques can very

play05:02

well be used as far as you have the

play05:04

required details or information related

play05:07

to the requirement that would be more

play05:08

than enough to define the or apply the

play05:11

techniques so let's have a look further

play05:13

to understand a little more at what this

play05:15

technique is trying to say so when it

play05:17

comes to the approach of writing the

play05:18

test cases there is a very significant

play05:21

way which we generally follow and all of

play05:22

us are not new to this we have been

play05:25

following this approach for a long time

play05:26

but still indeed let us discuss that

play05:29

what ATD strictly follows in terms of

play05:31

writing the test cases so very first

play05:33

thing here is that typically the first

play05:35

test cases are positive so first test

play05:37

case has to be with the valid set of

play05:39

data so that the happy path can be

play05:41

tested and it works as expected second

play05:44

confirming the correct Behavior without

play05:46

exceptions or error conditions and

play05:48

comprising the sequences of activities

play05:51

executed if everything goes as expected

play05:55

also after the positive test cases are

play05:57

done the team should perform negative

play05:59

testing and finally the team should

play06:01

cover the non-functional quality

play06:02

characteristics as well which includes

play06:04

performance efficiency usability Etc

play06:07

test cases should be expressed in a way

play06:10

that is understandable for the

play06:11

stakeholders so conclusively of course

play06:14

uh the test cases will always have the

play06:16

positive scenarios first as far as the

play06:18

positive test cases pass we look forward

play06:20

to run the negative test cases if in

play06:22

case the negative negative test cases

play06:24

are not working fine we certainly report

play06:26

the defects but at the same time we make

play06:28

sure that the test cases which are

play06:30

written it should be written in a way

play06:32

that can be understood by everyone in

play06:34

terms of stakeholders so it's not that

play06:36

we write high level test cases we do

play06:38

write some detailed test cases which

play06:40

helps any other stakeholders to

play06:43

understand them because in terms of

play06:44

failures when we report a defect there

play06:46

might be many other people who might be

play06:48

interested to go through your test case

play06:49

to understand how to reproduce a defect

play06:52

or sometime just to understand what was

play06:55

the reason for the failure so it's very

play06:57

important the way you write the test

play06:58

cases in agile is is also going to cover

play07:01

the language which helps anyone else to

play07:03

understand about your test cases further

play07:05

to add here of course typically the test

play07:08

cases contain sentences in natural

play07:10

languages involving the necessary

play07:12

preconditions the inputs and the post

play07:14

conditions which is a generic protocol

play07:16

of writing test cases however the test

play07:19

cases must cover all the characteristics

play07:21

of the user story and should not go

play07:24

beyond the story that means it should be

play07:26

limited and do specific very specific to

play07:30

the point in terms of what exactly is

play07:32

needed to be included writing

play07:34

unnecessary aspects of a story would

play07:36

result into confusions and implementing

play07:38

something which may not be needed which

play07:40

will turn into a longer duration as well

play07:43

so it is however the acceptance criteria

play07:46

May detail some of the issues described

play07:48

in the user story so it is very okay to

play07:52

talk about that the user stories can

play07:54

have issues related to what the

play07:57

challenges you can face on the way while

play07:59

implementing the story as well further

play08:02

to add in addition no two test cases

play08:04

should describe the same characteristics

play08:06

of the user story when captured in a

play08:08

format supported by a test automation

play08:11

framework the developer can automate the

play08:13

test cases by writing the supporting

play08:16

code as they implement the feature

play08:18

described by a user story so it's a very

play08:21

important and simple thing to understand

play08:23

that there should be no such two test

play08:25

cases which are duplicate of each other

play08:28

that means writing the same thing once

play08:29

again which might result into duplicacy

play08:32

of the work and if once we have taken

play08:34

care of that the implementation will be

play08:37

done after following your test cases so

play08:39

developers will now look at the copy of

play08:41

your test cases try to understand and

play08:43

then look forward to implement the code

play08:45

in order to make that test particularly

play08:47

pass so there will be repeated

play08:49

iterations in order to you know run

play08:52

failure will happen for the test then

play08:54

the code will be refactored then rerun

play08:56

refactored rerun till the test passes so

play08:59

they will developers will work in a very

play09:01

tight Loop in order to make the test

play09:04

pass and as when as in when the test

play09:06

passes the implementation is considered

play09:08

as done finally uh the acceptance test

play09:12

then becomes executable requirements for

play09:15

everyone that is for the implementation

play09:17

so put together that was one of the key

play09:20

approaches again from the agile

play09:22

perspective that how exactly do we

play09:23

design the test cases and uniquely

play09:25

differentiate with the collaborative

play09:27

approach of multi stakeholders together

play09:30

now in this case we do understand the

play09:32

test cases will be more efficient and

play09:34

will be revised and reviewed right at

play09:37

the time of creation itself and would

play09:39

help the developers to do the

play09:41

implementation as referring the

play09:43

requirement would be more of like

play09:45

referring your test cases so that's all

play09:47

from this particular tutorial team

play09:49

should you have anything else feel free

play09:50

to comment below I'm always there to

play09:52

address your queries and answer them

play09:53

well till then keep learning keep

play09:55

exploring keep understanding the context

play09:57

thanks for watching the video team and

play09:58

happy

play10:03

[Music]

play10:09

learning

Rate This

5.0 / 5 (0 votes)

関連タグ
Agile TestingISTQBATDDBDDTDDTest DesignAcceptance CriteriaCollaborative ApproachTest AutomationDevelopment ProcessQuality Assurance
英語で要約が必要ですか?