class_docstr: Unit test class for model creation process under various option values and
  types of input data.
class_docstr_tok: ["Unit","test","class","for","model","creation","process","under","various","option","values","and","types","of","input","data","."]
docstr: Test error trapping for bogus input datasets.
docstr_tok: ["Test","error","trapping","for","bogus","input","datasets","."]
code: def test_bad_data(self):
      """
      Test error trapping for bogus input datasets.
      """
  
      ## Empty SFrame
      with self.assertRaises(ToolkitError):
          m = tc.nearest_neighbor_classifier.create(
              dataset=tc.SFrame(), target="class", verbose=self.verbose
          )
  
      ## SArray for the features
      with self.assertRaises(ToolkitError):
          m = tc.nearest_neighbor_classifier.create(
              dataset=self.sf["int0"],
              target="class",
              verbose=self.verbose,
          )
  
      ## SArray for the target
      with self.assertRaises(ToolkitError):
          m = tc.nearest_neighbor_classifier.create(
              dataset=self.sf,
              target=self.sf["class"],
              verbose=self.verbose,
          )
  
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import absolute_import
  import unittest
  import copy
  import array
  import numpy
  import turicreate
  from .None import util
  from turicreate.util import _assert_sframe_equal
  from turicreate.toolkits._main import ToolkitError
  import sys
label_desc: Use image node_id 3 for calling the KnnClassifierCreateTest obj's underlying member method code with example usage: obj.test_bad_data() without return types