class_docstr: Note: Tests currently do a poor job of testing functionality
class_docstr_tok: ["Note",":","Tests","currently","do","a","poor","job","of","testing","functionality"]
docstr: test that usage of misc.TSNR trips a warning to use
  confounds.TSNR instead
docstr_tok: ["test","that","usage","of","misc.TSNR","trips","a","warning","to","use","confounds.TSNR","instead"]
code: def test_warning(self, mock_warn):
      """test that usage of misc.TSNR trips a warning to use
      confounds.TSNR instead"""
      # run
      misc.TSNR(in_file=self.in_filenames["in_file"])
  
      # assert
      assert True in [
          args[0].count("confounds") > 0
          for _, args, _ in mock_warn.mock_calls
      ]
  
file_path: nipype/nipype/algorithms/tests/test_TSNR.py
imports: from ...testing import utils
  from ..confounds import TSNR
  from ..None import misc
  import pytest
  import numpy.testing
  from unittest import mock
  import nibabel
  import numpy
  import os
label_desc: Use image node_id 6 for calling the TestTSNR obj's underlying member method code with example usage: obj.test_warning(mock_warn) without return types