class_docstr: Unit tests for the nearest neighbors builder class.
code: def test_add_samples_string_labels(self):
      builder = self.create_builder(default_class_label="default")
      self.assertIsNotNone(builder)
  
      some_X = self.training_X[:3]
      some_y = ["one", "two", "three"]
      builder.add_samples(some_X, some_y)
      self._validate_samples(builder.spec, some_X, some_y)
  
      addl_X = self.training_X[3:6]
      addl_y = ["four", "five", "six"]
      builder.add_samples(addl_X, addl_y)
      self._validate_samples(
          builder.spec, self.training_X[0:6], some_y + addl_y
      )
  
imports: import os
  import shutil
  from coremltools.models.utils import _is_macos
  import unittest
  from coremltools.models import MLModel
  from coremltools.models.nearest_neighbors import KNearestNeighborsClassifierBuilder
  from coremltools._deps import _HAS_SKLEARN
label_desc: Use image node_id 17 for calling the NearestNeighborsBuilderTest obj's underlying member method code with example usage: obj.test_add_samples_string_labels() without return types