Add in a test that ensures that we do not create more per-thread instances
than there are threads (even if using a factory)