code: def test_records_speaker_party():
      speaker_parties = ({"R"}, {"D", "I"})
      for speaker_party in speaker_parties:
          records = list(
              DATASET.records(speaker_party=speaker_party, limit=10)
          )
          assert len(records) >= 1
          assert all(
              meta["speaker_party"] in speaker_party
              for text, meta in records
          )
  
file_path: textacy/tests/datasets/test_capitol_words.py
imports: import datetime
  import os
  import pytest
  from textacy.datasets.capitol_words import CapitolWords
label_desc: Use image node_id 8 for calling a global function with example usage: test_records_speaker_party() without return types