Updated test/ to match the new explicit YAML format.
authorW. Trevor King <wking@drexel.edu>
Sun, 22 Aug 2010 05:54:12 +0000 (01:54 -0400)
committerW. Trevor King <wking@drexel.edu>
Sun, 22 Aug 2010 05:54:12 +0000 (01:54 -0400)
And other minor tweaks to get things passing again.
  $ nosetests --with-doctest --doctest-tests -vv test/ 2>&1 | less
  ...
  Ran 27 tests in 43.349s

  OK

Note that the tutorial.py and note.py tests were going so slowly
before (but are fast again now) because I was (re)loading
playlist/curve/etc. items in .__setstate__, when they are supposed to
be set with `listitems`.  If you're going to go messing around with
__getstate__ or __setstate__, it would be a good idea to read
  http://www.python.org/dev/peps/pep-0307/
(especially Case 2 and Case 3) *carefully* before wasting a bunch
of time and confusion bungling around like I did ;).

test/curve_info.py
test/hemingway_driver.py
test/jpk_driver.py
test/mfp3d_driver.py
test/picoforce_driver.py
test/tutorial.py
test/wtk_driver.py

index 28b14f38723262a03866a59cc500fb75cad48065..8dfc1eb7f1962714d2980ed6cb4fe602a3602eb6 100644 (file)
@@ -27,10 +27,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: picoforce.000
 path: .../test/data/picoforce.000
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.picoforce.PicoForceDriver object at 0x...>
 filetype: picoforce
 note: None
+command stack: []
 blocks: 2
 block sizes: [(2048, 2), (2048, 2)]
 Success
index 3ac273b70418d629886d801784ec486a655364a5..5c16cd682a89e5dedb438b6fe8acad16df267dcf 100644 (file)
@@ -29,10 +29,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: 20080428_a53t-0-0-10.dat
 path: .../test/data/fclamp_hemingway/20080428_a53t-0-0-10.dat
-experiment: <class 'hooke.experiment.ForceClamp'>
+experiment: <hooke.experiment.ForceClamp object at 0x...>
 driver: <hooke.driver.hemingway.HemingwayDriver object at 0x...>
 filetype: hemingway
 note: None
+command stack: []
 blocks: 1
 block sizes: [(14798, 5)]
 Success
index 8261c7e27994694c6e1ed3dab1ff46bbfc53c88d..f5b7ea0806c39938bf15bb206b6fe5a7093610b7 100644 (file)
@@ -29,10 +29,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: 2009.04.23-15.15.47.jpk
 path: .../test/data/vclamp_jpk/2009.04.23-15.15.47.jpk
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.jpk.JPKDriver object at 0x...>
 filetype: jpk
 note: None
+command stack: []
 blocks: 2
 block sizes: [(4096, 6), (4096, 4)]
 Success
index cefb85176789327d664f2ea71eeb68f641cd7f93..a291ae1ecf38909b471e47ae4715147dcb42166a 100644 (file)
@@ -29,10 +29,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: Line0004Point0000.ibw
 path: .../test/data/vclamp_mfp3d/Line0004Point0000.ibw
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.mfp3d.MFP3DDriver object at 0x...>
 filetype: mfp3d
 note: None
+command stack: []
 blocks: 3
 block sizes: [(491, 2), (497, 2), (105, 2)]
 Success
@@ -46,10 +47,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: Image0396.ibw
 path: .../test/data/vclamp_mfp3d/Image0396.ibw
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.mfp3d.MFP3DDriver object at 0x...>
 filetype: mfp3d
 note: None
+command stack: []
 blocks: 3
 block sizes: [(506, 3), (6, 3), (496, 3)]
 Success
index d36aa180e545755874ce1ce0517b5b4574e0e141..bac67835e620309bec56de2f002e58d251084c46 100644 (file)
@@ -29,10 +29,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: 20071120a_i27_t33.100
 path: .../test/data/vclamp_picoforce/20071120a_i27_t33.100
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.picoforce.PicoForceDriver object at 0x...>
 filetype: picoforce
 note: None
+command stack: []
 blocks: 2
 block sizes: [(2048, 2), (2048, 2)]
 Success
@@ -46,10 +47,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: 0x07200000
 path: .../test/data/vclamp_picoforce/0x07200000
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.picoforce.PicoForceDriver object at 0x...>
 filetype: picoforce
 note: None
+command stack: []
 blocks: 2
 block sizes: [(512, 2), (512, 2)]
 Success
@@ -60,10 +62,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: 0x06130001
 path: .../test/data/vclamp_picoforce/0x06130001
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.picoforce.PicoForceDriver object at 0x...>
 filetype: picoforce
 note: None
+command stack: []
 blocks: 2
 block sizes: [(2048, 2), (2048, 2)]
 Success
index 34bf1524a49850e2e1ad814df0d444c0b4efc2cd..558f6cf2b3c111a10224d42e9ba9c50f48551020 100644 (file)
@@ -96,10 +96,14 @@ False
 >>> h = r.run_lines(h, ['save_playlist --output mylist'])
 Success
 <BLANKLINE>
+>>> h = r.run_lines(h, ['name_playlist my_old_list'])
+<FilePlaylist my_old_list>
+Success
+<BLANKLINE>
 >>> os.path.isfile('mylist.hkp')
 True
 >>> h = r.run_lines(h, ['load_playlist mylist.hkp'])
-<FilePlaylist mylist.hkp>
+<FilePlaylist mylist>
 Success
 <BLANKLINE>
 >>> if playlist_already_exists == False:
@@ -163,22 +167,24 @@ Success
 Success
 <BLANKLINE>
 
+>>> [p for p in h.playlists]
+[<FilePlaylist my_old_list>, <FilePlaylist mylist>]
 >>> h = r.run_lines(h, ['get_playlist'])
-<FilePlaylist mylist>
+<FilePlaylist my_old_list>
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['next_playlist'])
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['get_playlist'])
-<FilePlaylist mylist.hkp>
+<FilePlaylist mylist>
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['previous_playlist'])
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['get_playlist'])
-<FilePlaylist mylist>
+<FilePlaylist my_old_list>
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['playlist_index'])
@@ -189,7 +195,7 @@ Success
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['get_playlist'])
-<FilePlaylist mylist.hkp>
+<FilePlaylist mylist>
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['playlist_index'])
@@ -200,7 +206,7 @@ Success
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['get_playlist'])
-<FilePlaylist mylist>
+<FilePlaylist my_old_list>
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['playlist_index'])
@@ -211,7 +217,7 @@ Success
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['get_playlist'])
-<FilePlaylist mylist.hkp>
+<FilePlaylist mylist>
 Success
 <BLANKLINE>
 >>> h = r.run_lines(h, ['playlist_index'])
index f34907caef8122b42bff302fd4eaaed4ddf1bcf8..0c9068a7b1cb12a75db09f8400528227ed2b3295 100644 (file)
@@ -44,10 +44,11 @@ Success
 >>> h = r.run_lines(h, ['curve_info']) # doctest: +ELLIPSIS, +REPORT_UDIFF
 name: 20100504144209_unfold
 path: .../test/data/vclamp_wtk/unfold/20100504/20100504144209_unfold
-experiment: <class 'hooke.experiment.VelocityClamp'>
+experiment: <hooke.experiment.VelocityClamp object at 0x...>
 driver: <hooke.driver.wtk.WTKDriver object at 0x...>
 filetype: wtk
 note: None
+command stack: []
 blocks: 2
 block sizes: [(810, 2), (8001, 2)]
 Success