In order to test the voting system, without getting 20 beta testers, I had to create some tests functions. One of them, for example, gives 100 votes (is a cheat, normally you only have 3 votes/election).
Another function adds fake players to the city and makes them candidates to various functions, so that you can vote on them and test how well the voting system works (check for bugs, especially).
Yet another test function is to invoke the election NOW (normally, the election is every month or so, and it's kind of boring to wait for so long to test it) :)
After this is done, the city Secretary (which is, btw, the most complex NPC) will need some other new menus, such as a referendum menu, where you can decide the following issues:
1. Remove someone from a function (mayor or advisories).
2. Remove a player from the city (only the mayor can start that referendum)
3. Remove a public structure from the city (factory, workshop, research lab, etc.). Again, only the mayor will be able to start such a referendum.
Then I also need to implement a few more menus, such as the one where the mayor approves or disapproves the pendign structures.