Hints - Mandatory 5 Blackbox Testing Pattern Hunting.

Slides:



Advertisements
Similar presentations
Welcome to. Who am I? A better way to code Design Patterns ???  What are design patterns?  How many are there?  How do I use them?  When do I use.
Advertisements

Introduction to Computer Programming in C
Detailed Design Kenneth M. Anderson Lecture 21
CSE 115 / 503 Introduction to Computer Science For Majors I Carl Alphonce 219 Bell Hall.
Soft. Eng. I, Fall 2006Dr Driss Kettani, from I. Sommerville1 CSC-3324: Chapter 6 Software Design Section 10.3 (except )
DAIMI(c) Henrik Bærbak Christensen1 BlackBox Testing based on Specification.
DAIMIHenrik Bærbak Christensen1 Mandatory Project Part II Software Reliability and Testing.
DAIMI(c) Henrik Bærbak Christensen1 JUnit A tool for test case management.
HENRIK BÆRBAK CHRISTENSEN ASSOCIATE PROFESSOR AARHUS UNIVERSITY DEPARTMENT OF COMPUTER SCIENCE 1 Experimental Software Architecture Kandidat orientering.
Spring 2010CS 2251 Design Patterns. Spring 2010CS 2252 What is a Design Pattern? "a general reusable solution to a commonly occurring problem in software.
PRE-PROGRAMMING PHASE
An Introduction to Design Patterns. Introduction Promote reuse. Use the experiences of software developers. A shared library/lingo used by developers.
Object Diagram Notation Lecture Oo11 Object Visibility.
1 Advanced Software Architecture Muhammad Bilal Bashir PhD Scholar (Computer Science) Mohammad Ali Jinnah University.
Domain Model Classes and Objects Association Structure Requirement Specification Domain Model.
Sheet 1 DocEng’03, Grenoble, November 2003 Model Driven Architecture based XML Processing Ivan Kurtev, Klaas van den Berg University of Twente, the Netherlands.
CS212: Object Oriented Analysis and Design Lecture 37: Design Pattern.
The HotCiv GUI Instantiating the MiniDraw Framework.
Test Stubs... getting the world under control. TDD of State Pattern To implement GammaTown requirements I CS, AUHenrik Bærbak Christensen2.
Cross Language Clone Analysis Team 2 March 3, 2011.
Henrik Bærbak Christensen1 Test Driven Development “TDD” Summary.
Henrik Bærbak Christensen1 Build Management Clean environment that works...
HotCiv Project Starting up!. Henrik Bærbak Christensen2 HotCiv = Agile development Iterations of –product development –learning increments.
AU CSHenrik Bærbak Christensen1 dSoftArk E2015 Software Architecture Programming in the Large.
Deriving State…...and an example of combining behaviour.
All the dSoftArk Tools Getting started!. Tools dSoftArk is a semi-realistic, agile, development project –Industrial strength software (programming, TDD,
Hints - Mandatory 2 / Strategies. Learning... life-a-curve.html B Christensen2 Jeg fatter ikke.
Multi Dimensional Variance: How to make ultra flexible software!
Applying the Principles Two Examples. Example 1 New Requirement It would be nice with a simple GUI “to see something” instead of just xUnit tests...
Refactoring and Integration Testing or Strategy, introduced reliably by TDD The power of automated tests.
AU CSHenrik Bærbak Christensen1 dSoftArk Software Architecture Programming in the Large.
AU CSHenrik Bærbak Christensen1 dSoftArk Software Architecture Programming in the Large.
MiniDraw Introducing a Framework... and a few patterns.
Henrik Bærbak Christensen1 Roles, Responsibilities and Behaviour What is an object? What is object-orientation?
Mandatory 2 / Strategies Note: I publish this presentation at the week plan for week 4.
Henrik Bærbak Christensen1 Systematic Testing (Scratching the surface) The art of economic testing...
Patterns are Roles What patterns are and what not…
1 Project 7: Looping. Project 7 For this project you will produce two Java programs. The requirements for each program will be described separately on.
AU CSHenrik Bærbak Christensen1 dSoftArk E2014 Software Architecture Programming in the Large.
Mandatory 3 Test Stubs State Abstract Factory. Stubs, Spies, and Fake Objects One Example Making distribution testable... Henrik Bærbak Christensen2.
Object Design More Design Patterns Object Constraint Language Object Design Specifying Interfaces Review Exam 2 CEN 4010 Class 18 – 11/03.
Mandatory 3 Test Stubs State Abstract Factory. Do not panic! dSoftArk is about Good analyzable design not about HotCiv! Henrik Bærbak Christensen2.
Strategy in 15 minutes... derived from the principles.
1 Welcome Alireza Humber College Lecture 1 Game 540 Alireza
Software Architecture in Practice A few notes on H1.
Instantiating the MiniDraw Framework
Introducing a Framework ... and a few patterns
Systematic Testing (Scratching the surface)
Software Design Patterns
Object-Oriented Software Engineering Using UML, Patterns, and Java,
Applying the Principles
Introduction to Design Patterns
Exam A few notes and hints….
HotCiv Project Starting up!.
Conditional Statements
Add and Subtract I explain what each digit represents in a four digit number. I can use materials or diagrams to explain how a 4-digit number could be.
Software Engineering and Architecture
Software Engineering and Architecture
FRAMEWORKS AND REUSE What is “Framework”?
Software Engineering and Architecture
Activity 1 - Chapter 5 -.
Software Engineering and Architecture
Container technology, Microservices, and DevOps
Software Engineering and Architecture
Software Engineering and Architecture
Software Engineering and Architecture
Software Engineering and Architecture
Software Engineering and Architecture
Software Engineering and Architecture
Software Engineering and Architecture
Presentation transcript:

Hints - Mandatory 5 Blackbox Testing Pattern Hunting

The UML Trap … which several TAs have fallen into… What is UML ? –1) A visual representation of a program –2) A visual language for expressing architecture Henrik Bærbak Christensen2

Then what is this? 1) An interface with a reference to an interface –Can we do that in Java? Henrik Bærbak Christensen3

And in Python Python has no interface language construct –But is an OO language Python uses ‘duck typing’ –Suitability is determined by the presence of methods, not by the object’s type Henrik Bærbak Christensen4

And in Python Python has no interface language construct –But is an OO language Can I realize this architecture in Python? Henrik Bærbak Christensen5

It is not a problem Just more ‘docs and conventions’ Henrik Bærbak Christensen6

The PayStation Henrik Bærbak Christensen7

And The Strategies I dealy miss my declared interface! –But ‘if it calculates time, it is a RateStrategy’ Henrik Bærbak Christensen8

The Bottom Line In FRS, UML expresses architecture Any implementation of PayStation ever must have a relation to a RateStrategy! –It is my architectural decision, and binds any who implements PayStation! Henrik Bærbak Christensen9

The Other Way If I had made the binding on PayStationImpl –PayStationImpl <>---- RateStrategy What had I then expressed as an architect??? Any Suggestions… Henrik Bærbak Christensen10

The TA Confusion Several hand-ins have been rejected that drew aggregations between Game interface and e.g. WinnerStrategy interfaces. –  TAs are humans and make mistakes –(Even the lecturer makes mistakes ) Talk to me and the TAs… Henrik Bærbak Christensen11

The Parametric Trap Sneaks in everywhere! Henrik Bærbak Christensen12

Henrik Bærbak Christensen13 Parametric design

Remedies It is a well known liability of the Strategy pattern that it may need to expose methods that are only relevant for some of its algorithm implementations… Henrik Bærbak Christensen14 Benefits Avoid bloats of switches Liability Less cohesion in Strategy Benefits Avoid bloats of switches Liability Less cohesion in Strategy

And …

The Heuristics Set or Boolean? Coverage and preconditions Four identificerede invalide ECs: r 15 [2] c 15 [5] –Fine to document them as ECs! But test cases ??? Henrik Bærbak Christensen16

Decorator How to ‘decorate and undecorate’? Name problems with this solution? Name a proper solution... Henrik Bærbak Christensen17

Non-Decorator Decorator adds behaviour – it does not invalidate it! Henrik Bærbak Christensen18

Next: About GUI for HotCiv Remember the virtues of TDD! Keep focus, take small steps –Download the NEW zip, unzip, and run the targets = green bar –Move one test class from your hotciv into folder struct. Loop until compile ok { move missing class into this struct } Henrik Bærbak Christensen19