code: def test_whitespace(text, expected_tokens, expected_indices):
      tk = create_whitespace_tokenizer()
  
      tokens = tk.tokenize(Message.build(text=text), attribute=TEXT)
  
      assert [t.text for t in tokens] == expected_tokens
      assert [t.start for t in tokens] == [
          i[0] for i in expected_indices
      ]
      assert [t.end for t in tokens] == [i[1] for i in expected_indices]
  
file_path: rasa/tests/nlu/tokenizers/test_whitespace_tokenizer.py
imports: import pytest
  from typing import Dict, Optional
  import rasa.shared.utils.io
  from rasa.nlu.constants import TOKENS_NAMES
  from rasa.shared.nlu.constants import TEXT, INTENT, ACTION_TEXT, ACTION_NAME
  from rasa.shared.nlu.training_data.training_data import TrainingData
  from rasa.shared.nlu.training_data.message import Message
  from rasa.nlu.tokenizers.whitespace_tokenizer import WhitespaceTokenizer
label_desc: Use image node_id 2 for calling a global function with example usage: test_whitespace(text, expected_tokens, expected_indices) without return types