### Question:
RandomTextDataGenerator { List<String> getRandomWords() { return Arrays.asList(words); } RandomTextDataGenerator(int size, int wordSize);   RandomTextDataGenerator(int size, Long seed, int wordSize);   }### Answer:
@Test public void testRandomTextDataGeneratorRepeatability() { RandomTextDataGenerator rtdg1 = new RandomTextDataGenerator(10, 0L, 5); List<String> words1 = rtdg1.getRandomWords(); RandomTextDataGenerator rtdg2 = new RandomTextDataGenerator(10, 0L, 5); List<String> words2 = rtdg2.getRandomWords(); assertTrue("List mismatch", words1.equals(words2)); }
@Test public void testRandomTextDataGeneratorUniqueness() { RandomTextDataGenerator rtdg1 = new RandomTextDataGenerator(10, 1L, 5); Set<String> words1 = new HashSet(rtdg1.getRandomWords()); RandomTextDataGenerator rtdg2 = new RandomTextDataGenerator(10, 0L, 5); Set<String> words2 = new HashSet(rtdg2.getRandomWords()); assertFalse("List size mismatch across lists", words1.equals(words2)); }