assert got_it : "findAll query failed to get our plugin";
query = em.createNamedQuery(ServerPlugin.QUERY_FIND_ALL_INSTALLED_KEYS);
List<PluginKey> allKeys = query.getResultList();
assert allKeys.size() == originalNumberOfPlugins + 1;
assert allKeys.contains(new PluginKey(plugin));
query = em.createNamedQuery(ServerPlugin.QUERY_FIND_KEYS_BY_IDS);
ArrayList<Integer> ids = new ArrayList<Integer>();
ids.add(plugin.getId());
query.setParameter("ids", ids);
allKeys = query.getResultList();
assert allKeys.size() == 1;
assert allKeys.contains(new PluginKey(plugin));
query = em.createNamedQuery(ServerPlugin.QUERY_GET_CONFIG_MTIMES);
query.setParameter("id", plugin.getId());
Object[] times = (Object[]) query.getSingleResult();
assert times[0] != null;