enthought / mayavi

3D visualization of scientific data in Python
http://docs.enthought.com/mayavi/mayavi/
Other
1.3k stars 284 forks source link

Address "ResourceWarning"s observed in the testsuite #1089

Closed rahulporuri closed 2 years ago

rahulporuri commented 2 years ago

This PR addresses ResourceWarnings raised in the testsuite because files were being opened and not closed in the testsuite.

Output from running the testsuite before this PR ``` (mayavi-test2)C:\Users\rporuri\work\github\ets\mayavi>python -W default -m nose.core -v mayavi C:\Users\rporuri\.edm\envs\mayavi-test2\lib\site-packages\nose\importer.py:12: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses from imp import find_module, load_module, acquire_lock, release_lock C:\Users\rporuri\.edm\envs\mayavi-test2\lib\runpy.py:125: RuntimeWarning: 'nose.core' found in sys.modules after import of package 'nose', but prior to execution of 'nose.core'; this may result in unpredictable behaviour warn(RuntimeWarning(msg)) C:\Users\rporuri\.edm\envs\mayavi-test2\lib\site-packages\pyface\base_toolkit.py:285: DeprecationWarning: SelectableGroups dict interface is deprecated. Use select. plugin for plugin in importlib_metadata.entry_points()[entry_point] C:\Users\rporuri\.edm\envs\mayavi-test2\lib\site-packages\pyface\base_toolkit.py:216: DeprecationWarning: SelectableGroups dict interface is deprecated. Use select. entry_point_group = importlib_metadata.entry_points()[entry_point] C:\Users\rporuri\work\github\ets\mayavi\tvtk\plugins\scene\i_scene_manager.py:6: PendingDeprecationWarning: Workbench will be moved from pyface.workbench to apptools.workbench at a future point from pyface.workbench.api import WorkbenchWindow Generic tests for 2D data arrays. ... ok Test for 3D data arrays. ... ok Tests if only the correct forms of input arrays are supported. ... ok Test if pickling works. ... ok test_add_attribute_raises_errors (mayavi.tests.test_array_source.TestArraySourceAttributes) ... ok test_add_attribute_works_for_cell_data (mayavi.tests.test_array_source.TestArraySourceAttributes) ... ok test_add_attribute_works_for_point_data (mayavi.tests.test_array_source.TestArraySourceAttributes) ... ok test_remove_attribute (mayavi.tests.test_array_source.TestArraySourceAttributes) ... ok test_rename_attribute (mayavi.tests.test_array_source.TestArraySourceAttributes) ... ok test_change (mayavi.tests.test_builtin_image.TestBuiltinImageSource) ... ok test_data_source (mayavi.tests.test_builtin_image.TestBuiltinImageSource) ... ok Test if saving a visualization and restoring it works. ... ok Test if it works fine on changing the source ... ok Do the basic testing ... ok Test if saving a visualization and restoring it works. ... ok test_mb_contour (mayavi.tests.test_composite_data.TestCompositeData) ... ok test_mb_scalar_cut_plane (mayavi.tests.test_composite_data.TestCompositeData) ... ok test_mb_surface (mayavi.tests.test_composite_data.TestCompositeData) ... ok test_mb_vector_cut_plane (mayavi.tests.test_composite_data.TestCompositeData) ... ok Test if the modules respond correctly when the components ... ok Test if the test fixture works ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok test_get_engine (mayavi.tests.test_core_common.TestCoreCommon) ... ok Check if the get_object_path method works correctly. ... ok Does obj.remove() work correctly ... ok test_that_custom_views_are_loaded (mayavi.tests.test_core_common.TestHandCraftedView) ... ok test_simple_timer (mayavi.tests.test_core_common.TestNoUITimer) ... ok test_timer_stops_on_error_and_raises (mayavi.tests.test_core_common.TestNoUITimer) ... ok test_timer_stops_on_stop_iteration (mayavi.tests.test_core_common.TestNoUITimer) ... ok test_get_range_works_for_VTKNoneArray (mayavi.tests.test_core_utils.TestDataSetHelper) ... ok test_get_range_works_for_multiblock_datasets (mayavi.tests.test_core_utils.TestDataSetHelper) ... ok test_get_range_works_for_simple_datasets (mayavi.tests.test_core_utils.TestDataSetHelper) ... ok test_API (mayavi.tests.test_csv_sniff.Test) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\AppData\\Local\\Temp\\tmp517fzd9q' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:69: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\AppData\\Local\\Temp\\tmp517fzd9q' mode='r' encoding='cp1252'> y = loadtxt(fo, **s.kwds()) ok test_comment (mayavi.tests.test_csv_sniff.Test) ... ok test_empty_file (mayavi.tests.test_csv_sniff.Test) ... ok test_nohead (mayavi.tests.test_csv_sniff.Test) ... ok test_tabs (mayavi.tests.test_csv_sniff.Test) ... ok test_11 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\11.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\11.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_1col (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\1col.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\1col.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_54 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\54.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\54.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_79 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\79.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\79.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_82 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\82.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\82.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_89 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\89.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\89.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_99 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\99.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\99.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_OObeta3 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\OObeta3.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\OObeta3.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_colors (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\colors.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\colors.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_example1 (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... SKIP test_hp11c (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\hp11c.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\hp11c.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_loc (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\loc.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\loc.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_multi_col (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\multi-col.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\multi-col.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_mydata (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\mydata.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\mydata.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_post (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\post.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\post.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok test_webaccess (mayavi.tests.test_csv_sniff.Test_csv_py_files) ... C:\Users\rporuri\work\github\ets\mayavi\mayavi\tests\test_csv_sniff.py:157: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\webaccess.py' mode='r' encoding='cp1252'> d = eval(open(f_py).read()) C:\Users\rporuri\work\github\ets\mayavi\mayavi\tools\data_wizards\csv_sniff.py:174: ResourceWarning: unclosed file <_io.TextIOWrapper name='C:\\Users\\rporuri\\work\\github\\ets\\mayavi\\mayavi\\tests\\csv_files\\webaccess.csv' mode='r' encoding='cp1252'> return loadtxt(self._filename, **self.kwds()) ok Test the import_contrib function. ... ok test_with_structured_data (mayavi.tests.test_cut_plane.TestCutter) ... ok test_with_unstructured_data (mayavi.tests.test_cut_plane.TestCutter) ... ok Does activating a particular array work. ... ok Does the add_array method work. ... ok Are the manager's cell arrays views of the VTK data? ... ok Are the cell arrays of the manager setup right? ... ok Are the manager's point arrays views of the VTK data? ... ok Are the point data arrays of the manager setup right? ... ok Does the remove_array method work correctly. ... ok Does array renaming work. ... ok test_get_engine_backend_auto_with_existing_engine (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_backend_envisage (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_backend_simple_with_existing_engine (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_backend_test (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_offscreen_backend_auto_switched_twice (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_offscreen_backend_auto_with_existing_engine (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_offscreen_backend_envisage (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_offscreen_backend_simple_with_started_engine (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_get_engine_offscreen_backend_test (mayavi.tests.test_engine_manager.TestEngineManager) ... ok test_extract_grid_filter_sample (mayavi.tests.test_extract_grid_filter.TestExtractGridFilter) ... SKIP: actor.bounds returns incorrect values test_voi (mayavi.tests.test_extract_grid_filter.TestExtractGridFilter) ... SKIP: actor.bounds returns incorrect values test_loop_loops_timesteps (mayavi.tests.test_file_timestep.TestFileDataSourceTimestep) ... ok test_play_calls_movie_maker_correctly (mayavi.tests.test_file_timestep.TestFileDataSourceTimestep) ... ok test_play_updates_timestep (mayavi.tests.test_file_timestep.TestFileDataSourceTimestep) ... ok test_sync_timesteps_steps_relevant_readers (mayavi.tests.test_file_timestep.TestFileDataSourceTimestep) ... ok test_update_files_updates_all_file_lists (mayavi.tests.test_file_timestep.TestFileDataSourceTimestep) ... ok test_update_files_updates_file_list (mayavi.tests.test_file_timestep.TestFileDataSourceTimestep) ... ok Tests if core Engine can be garbage collected. ... ok Tests if Mayavi UI Scene can be garbage collected. ... ok Tests if MlabSceneModel can be garbage collected. ... ok Tests if MlabSceneModel with GUI can be garbage collected. ... ok Tests if core Null Engine can be garbage collected. ... ok Tests if core Scene can be garbage collected. ... ok "Test if the modules respond correctly when the components ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if masking input points works with random mode. ... ok Test if masking input points works without random mode. ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok test_ipw_works_with_image_data_probe (mayavi.tests.test_image_plane_widget.TestImagePlaneWidgetNewPipeline) ... ok Test the image plane widget. ... ok test_default (mayavi.tests.test_mayavi_traits.TestArrayOrNone) ... ok test_no_compare (mayavi.tests.test_mayavi_traits.TestArrayOrNone) ... ok If trait_change_notify is honored. ... ok Test if the shadow property trait type works correctly. ... ok Test if the shadow property trait type works correctly. ... ok Test a simple trait wrapped as a shadow property. ... ok Test if the validation works correctly. ... ok test_animate_sets_up_movie_maker (mayavi.tests.test_mlab_integration.TestMlabAnimate) ... ok test_barchart (mayavi.tests.test_mlab_integration.TestMlabHelperFunctions) ... ok test_imshow (mayavi.tests.test_mlab_integration.TestMlabHelperFunctions) ... ok test_imshow_colormap (mayavi.tests.test_mlab_integration.TestMlabHelperFunctions) ... ok test_imshow_extent (mayavi.tests.test_mlab_integration.TestMlabHelperFunctions) ... ok test_volume_slice (mayavi.tests.test_mlab_integration.TestMlabHelperFunctions) ... ok test_axes (mayavi.tests.test_mlab_integration.TestMlabModules) ... ok Test the barchart function. ... ok Test the contour_grid_plane. ... ok Test the text module. ... ok Test the text3d module. ... ok Test the mlab volume factory. ... ok test_add_dataset_works_with_vtk_datasets (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok Various tests for mlab.close(). ... ok Test that when an object with scalars hidden is created, it ... ok test_contour_filter (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok Various tests for mlab.figure(). ... ok test_mlab_source (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok test_set_active_attribute (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok test_slice_unstructured_grid (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok test_source_can_save_output_to_file (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok test_strange_vmin_vmax (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok When reseting the triangular mesh (ie polydata), if we are ... ok test_user_defined_filter (mayavi.tests.test_mlab_integration.TestMlabNullEngineMisc) ... ok Test probe_data ... ok test_glyph_reset_twice_with_fewer_points (mayavi.tests.test_mlab_integration.TestSourceReset) ... ok test_lines_reset_twice_with_fewer_points (mayavi.tests.test_mlab_integration.TestSourceReset) ... ok test_mesh_reset_twice_with_fewer_points (mayavi.tests.test_mlab_integration.TestSourceReset) ... ok test_trimesh_reset_twice_with_fewer_points (mayavi.tests.test_mlab_integration.TestSourceReset) ... ok Test if setting the backend to 'test' works. ... ok Check that plotting to scene attributes using their ... ok Test if the various static handlers work correctly. ... ok test_reset (mayavi.tests.test_mlab_source.TestMArray2DSource) ... ok Test if the set method works correctly. ... ok Test if the various static handlers work correctly. ... ok Test the reset method. ... ok Test if the set method works correctly. ... ok Test if the various static handlers work correctly. ... ok Test the reset method. ... ok Test the reset method. ... ok Test if the set method works correctly. ... ok Test if the various static handlers work correctly. ... ok Test if the various static handlers work correctly for strange shapes. ... ok test_reset_changes_pipeline (mayavi.tests.test_mlab_source.TestMGlyphSource) ... ok Test the reset method when the inputs are 2-d arrays. ... ok test_reset_with_resized_data (mayavi.tests.test_mlab_source.TestMGlyphSource) ... ok test_reset_with_same_size_data (mayavi.tests.test_mlab_source.TestMGlyphSource) ... ok Test if the set method works correctly. ... ok Test the MGlyphSource with strange shapes for the arguments ... ok Test if the various static handlers work correctly. ... ok Test the reset method. ... ok test_reset_changes_pipeline (mayavi.tests.test_mlab_source.TestMGridSource) ... ok Test if the set method works correctly. ... ok Test if the various static handlers work correctly. ... ok Test the reset method. ... ok Test the reset method. ... ok test_reset_changes_pipeline (mayavi.tests.test_mlab_source.TestMLineSource) ... ok Test if the set method works correctly. ... ok test_set_without_scalars_attribute_works (mayavi.tests.test_mlab_source.TestMLineSource) ... ok test_set_without_scalars_works (mayavi.tests.test_mlab_source.TestMLineSource) ... ok Change the number of the points, and establish ... ok Test if the various static handlers work correctly. ... ok Test the reset method. ... ok test_reset_changes_pipeline (mayavi.tests.test_mlab_source.TestMTriangularMeshSource) ... ok Test if the set method works correctly. ... ok Test if the various static handlers work correctly. ... ok Test the reset method. ... ok Test the reset method. ... ok Test if the set method works correctly. ... ok Check that array2d_source can take different input arguments ... ok Check that vector_field can take different input arguments ... ok Check that scalar_field can take different input arguments ... ok Check that scalar_scatter can take different input arguments ... ok Check that vector_field can take different input arguments ... ok Check that vector_scatter can take different input arguments ... ok Check that passing in arrays with infinite values raises ... ok test_callback_registering (mayavi.tests.test_mouse_pick_dispatcher.TestMousePickerDispatcher) ... ok Test if mayavi imports work without any UI (wx or PyQt4). ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Is the default PipelineInfo class built right. ... ok Can tvtk datasets can be converted to names correctly. ... ok test_deepcopied (mayavi.tests.test_plot3d_mb_reader.TestPlot3dMbReader) ... ok test_plot3d_mb_reader (mayavi.tests.test_plot3d_mb_reader.TestPlot3dMbReader) ... ok test_save_and_restore (mayavi.tests.test_plot3d_mb_reader.TestPlot3dMbReader) ... ok Test if the test fixture works ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok test_ply_data_reader (mayavi.tests.test_poly_data_reader.TestPLYReader) ... ok test_save_and_restore (mayavi.tests.test_poly_data_reader.TestPLYReader) ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the test fixture works ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the test fixture works ... ok Are the traits properly mirrored? ... ok mirror must not sync changes back to the original preferences. ... ok Are Mirror's preferences saved correctly ... ok Does the mirror listen for changes on original preference. ... ok Test if lut_manager can be loaded despite faulty pylab_luts.pkl ... SKIP: mayavi.core.lut_manager is already loaded in another tests. Can't run this test. Test the clear method. ... ok Is the object imported and created if unknown? ... ok Test if a list item is changed does the change get recorded. ... ok Can classes not using traits be handled? ... ok Does the object path update when a list has changed? ... ok Does recording work correctly. ... ok See if recordable function calls are handled correctly. ... ok Does recording work right when a trait is replaced. ... ok Test if recorder trait is set and private traits are ignored. ... ok Test if saving tape to file works. ... ok Test if setting script_id at registration time works. ... ok Does the get_unique_id method work. ... ok Test the write_script_id_in_namespace method. ... ok Test if reader conflict is resolved ... ok Test if the fixture works fine if there are multiple readers ... ok Test that if there is no reader which can read the file with ... ok Check if a file with a unique reader in Mayavi2 can be read ... ok Test if the mechanism to handle unsupported files works fine ... ok Does script recording work correctly. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the test fixture works ... ok Test if the convert_to_arrays routine works properly ... ok Test if the modules respond correctly when the components ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the test fixture works ... ok Test if changing 'orient_to_camera' switches between plain ... ok test_persistence (mayavi.tests.test_text3d.TestText3D) ... ok Test if the text3d has been properly instanciated ... ok test_threshold_filter_data_range_changes (mayavi.tests.test_threshold_filter.TestThresholdFilter) ... ok test_threshold_filter_nan (mayavi.tests.test_threshold_filter.TestThresholdFilter) ... ok test_threshold_filter_threhsold (mayavi.tests.test_threshold_filter.TestThresholdFilter) ... ok test_threshold_with_other_filter_as_input (mayavi.tests.test_threshold_filter.TestThresholdFilter) ... ok Test if the test fixture works ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the point and cell data is parsed correctly. ... SKIP: ExodusIIReader support is disabled for now. Test if the MayaVi2 visualization can be deep-copied. ... SKIP: ExodusReader is not supported VTK 6.0 onwards. Test if the test fixture works ... SKIP: ExodusReader is not supported VTK 6.0 onwards. Test if saving a visualization and restoring it works. ... SKIP: ExodusReader is not supported VTK 6.0 onwards. Test if the MayaVi2 visualization can be deep-copied. ... ok Test if the test fixture works ... ok Test if saving a visualization and restoring it works. ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the test fixture works ... ok test_volume_works_with_probe (mayavi.tests.test_volume.TestVolumeWorksWithProbe) ... ok Test if adding a source as a child works correctly. ... ok test_deepcopied (mayavi.tests.test_vtk_data_source.TestVTKDataSource) ... ok Test if saving a visualization and restoring it works. ... ok test_vtk_data_source (mayavi.tests.test_vtk_data_source.TestVTKDataSource) ... ok test_add_attribute_raises_errors (mayavi.tests.test_vtk_data_source.TestVTKDataSourceAttributes) ... ok test_add_attribute_works_for_cell_data (mayavi.tests.test_vtk_data_source.TestVTKDataSourceAttributes) ... ok test_add_attribute_works_for_point_data (mayavi.tests.test_vtk_data_source.TestVTKDataSourceAttributes) ... ok test_remove_attribute (mayavi.tests.test_vtk_data_source.TestVTKDataSourceAttributes) ... ok test_rename_attribute (mayavi.tests.test_vtk_data_source.TestVTKDataSourceAttributes) ... ok test_field_file (mayavi.tests.test_vtk_file_reader.TestVTKFileReader) ... ok test_polydata_file (mayavi.tests.test_vtk_file_reader.TestVTKFileReader) ... ok test_rectiliner_grid_file (mayavi.tests.test_vtk_file_reader.TestVTKFileReader) ... ok test_structured_grid_file (mayavi.tests.test_vtk_file_reader.TestVTKFileReader) ... ok test_structured_points_file (mayavi.tests.test_vtk_file_reader.TestVTKFileReader) ... ok test_unstructured_grid_file (mayavi.tests.test_vtk_file_reader.TestVTKFileReader) ... ok test_add_dataset_uses_vtk_data_source_for_datasets (mayavi.tests.test_vtk_object_source.TestVTKObjectSource) ... ok test_add_dataset_uses_vtk_object_source_for_objects (mayavi.tests.test_vtk_object_source.TestVTKObjectSource) ... ok test_data_changed_is_fired_when_object_is_modified (mayavi.tests.test_vtk_object_source.TestVTKObjectSource) ... ok test_simple_vtk_object_source (mayavi.tests.test_vtk_object_source.TestVTKObjectSource) ... ok test_vtk_object_source_works_with_any_vtk_object (mayavi.tests.test_vtk_object_source.TestVTKObjectSource) ... ok Test if the MayaVi2 visualization can be deep-copied. ... ok Test if saving a visualization and restoring it works. ... ok Test if the test fixture works ... ok ---------------------------------------------------------------------- Ran 307 tests in 22.986s OK (SKIP=8) ```