testing with ctest and cdash
Download
Skip this Video
Download Presentation
Testing with CTest and CDash

Loading in 2 Seconds...

play fullscreen
1 / 22

Testing with CTest and CDash - PowerPoint PPT Presentation


  • 139 Views
  • Uploaded on

Testing with CTest and CDash. Julien Jomier Kitware Inc. Testing Overview. Developers. CVS/SVN. Web Browser. CTest. CDash. Testing Terminology. Sites. Builds. dash5.kitware. Linux-g++. Linux-gcc4. Linux-gcc3. iris.elmtech. Dashboard. Why Test Daily?.

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Testing with CTest and CDash' - tarmon


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
testing with ctest and cdash

Testing with CTest and CDash

Julien JomierKitware Inc.

testing overview
Testing Overview

Developers

CVS/SVN

Web Browser

CTest

CDash

testing terminology
Testing Terminology

Sites

Builds

dash5.kitware

Linux-g++

Linux-gcc4

Linux-gcc3

iris.elmtech

Dashboard

why test daily
Why Test Daily?
  • Large code base too large for any single developer to understand
  • Developers distributed around the world
  • Identify problems as they occur
  • Insure that object API remains unchanged
  • Provide feedback to developers as they experiment with new implementations
if it s not tested it doesn t work
“If it’s not tested it doesn’t work”
  • Dasboards and Software Process
    • Roots in GE Six Sigma initiative
  • Cross platform testing
  • Nightly regression testing Memory (Purify/ValGrind) testing
  • Coverage testing
  • Style checking
  • Documentation evaluation
how to write a good test
How to write a good test?
  • Use empirical values (5/2=2.5)
  • Test most of the use cases (even the boring/most difficult ones)
  • Make your tests as efficient as possible
  • Have someone else write the test for your algorithm
regression testing
Regression Testing
  • Compare generated image against standard “correct” image
    • pixel-by-pixel comparison
    • can use a threshold metric
    • adjusted for effects like dithering
ctest
CTest
  • Testing client
  • Distributed with CMake
  • Submit test results to the dashboard
  • XML submission
  • Independent of CMake
ctest with cmake
CTest with CMake

CMakeLists.txt

INCLUDE(CTest)

ENABLE_TESTING()

# Add a simple test

ADD_TEST(CDashTest1 CDashTest CDashTest)

ADD_EXECUTABLE(CDashTest main.cxx)

CTestConfig.txt

set(CTEST_PROJECT_NAME "MyProject")

set(CTEST_NIGHTLY_START_TIME "21:00:00 EDT")

set(CTEST_DROP_METHOD "http")

set(CTEST_DROP_SITE "localhost")

set(CTEST_DROP_LOCATION "/CDash/submit.php?project=MyProject")

set(CTEST_DROP_SITE_CDASH TRUE)

testing submission
Testing Submission

Compiler/Tester

CDash

CTest

Backup XML File

HTTP PUT

Fill Database

XML Submission

XML Parsing

Update.xml

Configure.xml

Build.xml

Test.xml

Coverage.xml

DynamicAnalysis.xml

Send Email

Update RSS Feed

cdash
CDash
  • New generation of Dart
  • Written in Php/Javascript
  • MySQL
  • Open Source
  • Run on top of a web server
  • XSL implementation
  • Web 2.0
cdash features
CDash Features
  • Ajax requests
  • Graphs: build, test times
  • Builds group
  • User management
  • Email notifications
  • Timing defects
coverage support
Coverage Support
  • Email Low Coverage
  • Bullseye support
build notes
Build Notes
  • Share with other developers
  • Keep it simple
my cdash
My CDash
  • Personal Page
  • Subscribe to project
  • View sites
  • Email preferences
project roles
Project Roles
  • Normal user
  • Site maintainer
  • Project administrator
claiming sites
Claiming Sites
  • Site information
  • Automatic (CTest 2.6)
  • Information history
  • Manual editing
  • Personal view/email
cdash misc
CDash Misc.
  • Automatic Geolocation from IP addresses
  • Support for iPhone
installing cdash
Installing CDash
  • (L/W)AMP : Apache, MySQL, PHP- XAMPP, EasyPHP
  • Download CDash (www.cdash.org) in your Apache web directory
  • Edit config.php
  • Point Web Browser to CDash- Setup the database- Create first project
style checking
Style Checking
  • KWStyle
  • C++ Style checker
  • Configuration via XML
  • HTML Generator (TBI in CDash)
  • Open Source
  • Written in C++
contribute
Contribute
  • Website- http://www.cdash.org- http://public.kitware.com/KWStyle
  • Bug Tracker- http://www.cmake.org/Bug
  • Mailing List- http://public.kitware.com/cgi-bin/mailman/listinfo/cdash
ad