code: def test_generate(self):
      # test task transformation
      gene = WSDGenerator(
          trans_methods=ALLOWED_TRANSFORMATIONS["WSD"], sub_methods=[]
      )
      for original_samples, trans_rst, trans_type in gene.generate(
          dataset
      ):
          if original_samples is None:
              continue
          self.assertTrue(len(original_samples) == len(trans_rst))
          for index in range(len(original_samples)):
              self.assertTrue(
                  original_samples[index] != trans_rst[index]
              )
  
      # test wrong trans_methods
  
      gene = WSDGenerator(
          trans_methods=["wrong_transform_method"], sub_methods=[]
      )
  
      self.assertRaises(ValueError, next, gene.generate(dataset))
      gene = WSDGenerator(trans_methods=["AddSubtree"], sub_methods=[])
      self.assertRaises(ValueError, next, gene.generate(dataset))
      gene = WSDGenerator(trans_methods="OOV", sub_methods=[])
      self.assertRaises(ValueError, next, gene.generate(dataset))
  
imports: import unittest
  from textflint.input.dataset import Dataset
  from textflint.generation.generator.wsd_generator import WSDGenerator
  from textflint.common.settings import ALLOWED_TRANSFORMATIONS
label_desc: Use image node_id 1 for calling the TestWSDGenerator obj's underlying member method code with example usage: obj.test_generate() without return types