code: def test_errors(self):
      with self.assertRaisesRegex(ValueError, "must be a string"):
          name_scope("foo/bar")
      with self.assertRaisesRegex(ValueError, "must be a string"):
          name_scope(4)
  
file_path: keras/keras/backend/common/name_scope_test.py
imports: from keras import testing
  from keras.backend.common.name_scope import current_path
  from keras.backend.common.name_scope import name_scope
label_desc: Use image node_id 3 for calling the NameScopeTest obj's underlying member method code with example usage: obj.test_errors() without return types