code: def test_should_build_training_data_with_no_noise(
      self, mocked_augment_utterances
  ):
      # Given
      dataset_stream = io.StringIO(
          """
  ---
  type: intent
  name: my_first_intent
  utterances:
  - how are you
  - hello how are you?
  - what's up
  
  ---
  type: intent
  name: my_second_intent
  utterances:
  - what is the weather today ?
  - does it rain
  - will it rain tomorrow"""
      )
      dataset = Dataset.from_yaml_files("en", [dataset_stream]).json
      resources = self.get_resources(dataset[LANGUAGE])
      mocked_augment_utterances.side_effect = (
          get_mocked_augment_utterances
      )
      random_state = np.random.RandomState(1)
  
      # When
      data_augmentation_config = IntentClassifierDataAugmentationConfig(
          noise_factor=0
      )
      utterances, _, intent_mapping = build_training_data(
          dataset,
          LANGUAGE_EN,
          data_augmentation_config,
          resources,
          random_state,
      )
  
      # Then
      expected_utterances = [
          utterance
          for _, intent in sorted(iteritems(dataset[INTENTS]))
          for utterance in intent[UTTERANCES]
      ]
      expected_intent_mapping = ["my_first_intent", "my_second_intent"]
      self.assertListEqual(expected_utterances, utterances)
      self.assertListEqual(expected_intent_mapping, intent_mapping)
  
imports: from __future__ import unicode_literals
  import io
  from copy import deepcopy
  from itertools import cycle
  import numpy
  from future.utils import itervalues, iteritems
  from mock import MagicMock, patch
  from snips_nlu.constants import INTENTS, LANGUAGE_EN, UTTERANCES, LANGUAGE, NOISE
  from snips_nlu.dataset import validate_and_format_dataset, Dataset
  from snips_nlu.intent_classifier.log_reg_classifier_utils import add_unknown_word_to_utterances, build_training_data, generate_noise_utterances, generate_smart_noise, get_noise_it, remove_builtin_slots, text_to_utterance
  from snips_nlu.pipeline.configs import IntentClassifierDataAugmentationConfig, LogRegIntentClassifierConfig
  from snips_nlu.tests.test_log_reg_intent_classifier import get_mocked_augment_utterances
  from snips_nlu.tests.utils import SnipsTest, get_empty_dataset
label_desc: Use image node_id 1 for calling the TestLogRegClassifierUtils obj's underlying member method code with example usage: obj.test_should_build_training_data_with_no_noise(mocked_augment_utterances) without return types