@Test
    void textCopyAll() {
        assertThat(indexFieldDao.getFieldCount(DOC_REF_1)).isEqualTo(0);
        indexFieldDao.addField(new AddField(DOC_REF_1, FIELD_1));
        indexFieldDao.addField(new AddField(DOC_REF_1, FIELD_2));
        indexFieldDao.addField(new AddField(DOC_REF_1, FIELD_3));
        assertThat(indexFieldDao.getFieldCount(DOC_REF_1)).isEqualTo(3);

        assertThat(indexFieldDao.getFieldCount(DOC_REF_2)).isEqualTo(0);
        indexFieldDao.copyAll(DOC_REF_1, DOC_REF_2);
        assertThat(indexFieldDao.getFieldCount(DOC_REF_1)).isEqualTo(3);
        assertThat(indexFieldDao.getFieldCount(DOC_REF_2)).isEqualTo(3);
    }
Make sure multiple threads can concurrently add different lists of fields
stroom-index/stroom-index-impl-db/src/test/java/stroom/index/impl/db/TestIndexFieldDaoImpl.java