source: trunk/gui/test/vtkisosurfaceviewer.test @ 6066

Last change on this file since 6066 was 6066, checked in by ldelgass, 9 years ago

Fix isosurface viewer test (hostlist argument was removed)

File size: 1.8 KB
Line 
1# Commands covered:
2# Rappture::VtkIsosurfaceViewer
3#
4# This file contains a collection of tests for one of the Rappture Tcl
5# commands.  Sourcing this file into Tcl runs the tests and
6# generates output for errors.  No output means no errors were found.
7#
8# ======================================================================
9# AUTHORS:
10#   Derrick Kearney, Purdue University
11#   Leif Delgass, Purdue University
12# Copyright (c) 2004-2016  HUBzero Foundation, LLC
13#
14# See the file "license.terms" for information on usage and redistribution
15# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
16
17
18if {[lsearch [namespace children] ::tcltest] == -1} {
19    package require tcltest
20    package require Rappture
21    package require RapptureGUI
22    namespace import -force ::tcltest::*
23}
24
25#----------------------------------------------------------
26#----------------------------------------------------------
27# constructor
28#
29# Rappture::VtkIsosurfaceViewer <name> <servers>
30#----------------------------------------------------------
31test vtkisosurfaceviewer.constructor.1 {
32    constructor, 0 args, auto named
33} -setup {
34} -body  {
35    list [catch {Rappture::VtkIsosurfaceViewer .#auto} msg] $msg
36} -cleanup {
37    destroy .vtkIsosurfaceViewer0
38} -result {0 .vtkIsosurfaceViewer0}
39
40test vtkisosurfaceviewer.constructor.2 {
41    value command, explicit name, -plotbackground option
42} -setup {
43} -body  {
44    catch {Rappture::VtkIsosurfaceViewer .foo -plotbackground red} msg
45} -cleanup {
46    destroy .foo
47} -result {0}
48
49test vtkisosurfaceviewer.constructor.3 {
50    value command, bad option
51} -setup {
52} -body  {
53    list [catch {Rappture::VtkIsosurfaceViewer .foo -nonexistent foo} msg] $msg
54} -cleanup {
55    destroy .foo
56} -result {1 {unknown option "-nonexistent"}}
57
58::tcltest::cleanupTests
59return
Note: See TracBrowser for help on using the repository browser.