• No results found

Modulo II Qualidade de Software com Maven

N/A
N/A
Protected

Academic year: 2021

Share "Modulo II Qualidade de Software com Maven"

Copied!
18
0
0

Loading.... (view fulltext now)

Full text

(1)

April 05 Prof. Ismael H. F. Santos - [email protected] 1

Modulo II

Qualidade de Software

com Maven

Professor

Ismael H F Santos –

[email protected]

„

Linguagem de Programação JAVA

„

Ismael H. F. Santos, Apostila UniverCidade, 2002

„

The Java Tutorial: A practical guide for programmers

„

Tutorial on-line:

http://java.sun.com/docs/books/tutorial

„

Java in a Nutshell

„

David Flanagan, O´Reilly & Associates

„

Just Java 2

„

Mark C. Chan, Steven W. Griffith e Anthony F. Iasi, Makron

Books.

„

Java 1.2

„

Laura Lemay & Rogers Cadenhead, Editora Campos

(2)

Julho 06 Prof. Ismael H. F. Santos 3

Livros

„

Core Java 2

, Cay S. Horstmann, Gary Cornell

„

Volume 1 (Fundamentos)

„

Volume 2 (Características Avançadas)

„

Java: Como Programar

, Deitel & Deitel

„

Thinking in Patterns with JAVA

, Bruce Eckel

„

Gratuito. http://www.mindview.net/Books/TIJ/

Ementa

„

Visão geral do MAVEN

„

Entendendo o POM (Project Object Model)

„

Executando um build

(3)

Julho 06 Prof. Ismael H. F. Santos 5

Apache

Maven

POO-Java

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

XWiki)

(4)

Julho 06 Prof. Ismael H. F. Santos 7

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

XWiki)

(5)

Julho 06 Prof. Ismael H. F. Santos 9

„

Passive quality = after the fact

Active and Passive quality

checks are both required…

… but moving to active is the

(6)

Julho 06 Prof. Ismael H. F. Santos 11

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

XWiki)

Surefire

JUnit and

TestNG

PMD

Checkstyle

Verifier

Clover

Changelog

Changes

In Maven

In Mojo

In Mojo Sandbox

Quality-related plugins

Cargo

Jetty

QALab

Clirr

Cobertura

Jalopy

JDepend

JavaNCSS

JDiff

Selenium

JBoss

DBUnit

Jardiff

JCoverage

FindBugs

Simian

Emma

Fit

Tomcat

WebLogic

Elsewhere

(7)

Julho 06 Prof. Ismael H. F. Santos 13

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

XWiki)

Local

Maven Repo

Local

Maven Repo

Build Tools

Module

Build Tools

Module

be checked

Module to

Module to

be checked

build-tools.jar

Depends on

build-tools.jar

Coding conventions with

(8)

Julho 06 Prof. Ismael H. F. Santos 15

Coding conventions with

Checkstyle

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

(9)

Julho 06 Prof. Ismael H. F. Santos 17

Binary compatibility with Clirr

„

Automatically compares previous version API with

current sources

„

To try it quickly: mvn clirr:check

„

Can generate reports too:

„

Strategy: Exclude files that have voluntary

violations

(10)

Julho 06 Prof. Ismael H. F. Santos 19

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

XWiki)

Automated functional tests with Cargo

„

Cargo

: A Java API to manipulate containers

(install, configure, start, stop, deploy)

„

Has extensions for Ant, Maven1, Maven2, IntelliJ

IDEA*, Netbeans*

„

Currently support J2EE containers

„

Tomcat, Orion, Resin, Jetty, WebLogic, OC4J,

Geronimo, Jboss, jo!

„

Upcoming: Glassfish, WebSphere

„

Upcoming: database support

(11)

Julho 06 Prof. Ismael H. F. Santos 21

Automated functional tests with Cargo

Install distribution

Install distribution

Configure container

Configure container

Deploy

Deploy

Start container

Start container

Run tests

Run tests

Stop container

Stop container

Install from URL

Ex:

http://www.caucho.com/download/resin-3.0.19.zip

Either created by Cargo or use an existing

configuration

Deploy WAR, EAR, EJBs, etc

Use any tool: JUnit, TestNG, Selenium, etc

It’s also possible to deploy to an already

started container

(12)

Julho 06 Prof. Ismael H. F. Santos 23

Full build automation

Library builds

Library builds

Generate JARs

Components builds

Components builds

Generate WARs, EARs, etc

Databases build

Databases build

Generate databases with schema and data

loaded (output is typically ZIP files)

Containers build

Containers build

Generate fully configured containers with

deployed components (output is typically

ZIP files)

Applications build

Applications build

Generate fully working applications

(includes both containers and databases

build outputs)

Unit tests

Functional

tests

Integration

tests

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

(13)

Julho 06 Prof. Ismael H. F. Santos 25

Test coverage with Clover

Module 1

Module 1

Module 2

Module 2

Module 3

Module 3

Depends on

Local Repository

module1-clover.jar

module1-clover.jar

module2-clover.jar

module2-clover.jar

module3-clover.jar

module3-clover.jar

Build

De

pe

nde

ncy

Depends on

Build

Build

Test coverage with Clover

(14)

Julho 06 Prof. Ismael H. F. Santos 27

Agenda

„

Active Quality vs Passive Quality

„

Review of Quality-related plugins

„

Coding conventions with Checkstyle

„

Binary compatibility with Clirr

„

Automated functional tests with Cargo

„

Test coverage with Clover

„

Project documentation with a wiki (Demo of

XWiki)

Project documentation with a wiki

„

Pros

„

Easier participation and collaboration of everyone

„

Even non-committers

„

Always published; WYSIWYG

„

Dynamic pages

„

Get code snippets from SVN

„

Mini-Applications like on the fly charts for development

metrics, etc

„

Cons

„

Versioned separately from the sources

(15)

Julho 06 Prof. Ismael H. F. Santos 29

XWiki demo

(16)

Julho 06 Prof. Ismael H. F. Santos 31

Example:

http://www.bestventes.com

(17)

Julho 06 Prof. Ismael H. F. Santos 33

Example:

http://www.capdigital.com

Example:

(18)

Julho 06 Prof. Ismael H. F. Santos 35

Example: http://new.uaic.ro

Example:

References

Related documents

Update Notes – This button updates all changes on the Early Alert form, and saves them into a row in the Current Student History Table.. Email & Print Letter – prints/emails

The purpose was to extend DNS conducted between two parallel plane walls to flows with a range of pressure gradients, relative to the common case of Poiseuille flow which has only

Non Smoking Rooms Available: Yes, No, Available Private Bath Refrigerator in Room Television Tours Tour - Guided Tour – Other: Tour - Segway Tour - Self Guided Tour

The founder, Shaykh Mustafa Husein is an ulama affiliated with Nahdlatul Ulama who obtained the religious sciences in Mecca where he studied to a number of important scholars such

While existing ap- proaches obfuscate graph data by adding or removing edges entirely, we propose using a finer-grained perturbation that adds or removes edges partially : this way

Characteristics of included studies (Continued) neg- ative sepsis) vs 53.. 7) Sepsis (gen- eral) Mix/ un- clear Not re- ported Acute pyelonephri- tis, pneu- monia, diges- tive

This volume contains the revised accepted papers selected from among those presented at the 8th Italian Research Conference on Digital Libraries (IRCDL 2012), which was held at