public void testIndianCapital() {
        ((FileOption) spec().getOption(MapGeneratorOptions.IMPORT_FILE)).setValue(null);

        Game g = new ServerGame(spec());
        g.setNationOptions(new NationOptions(spec(), Advantages.SELECTABLE));

        MapGenerator gen = new SimpleMapGenerator(new Random(1), spec());

        Vector<Player> players = new Vector<Player>();

        for (Nation n : spec().getNations()) {
            Player p = new ServerPlayer(g, n.getType().getNameKey(), false, n,
                                        null, null);
            p.setAI(!n.getType().isEuropean() || n.getType().isREF());
            g.addPlayer(p);
            players.add(p);
        }

        try {
            gen.createMap(g);
        } catch (FreeColException e) {
            fail();
        }

        // Check that the map is created at all
        assertNotNull(g.getMap());

        for (Player p : players) {
            if (!p.isIndian())
                continue;

            // Check that every indian player has exactly one capital if s/he
            // has at least one settlement.
            int settlements = 0;
            int capitals = 0;
            for (IndianSettlement s : p.getIndianSettlements()) {
                settlements++;
                if (s.isCapital())
                    capitals++;
            }
            if (settlements > 0) 
                assertEquals(1, capitals);
        }
    }