Bug 82173 [5.0][typing] Angle Bracket<> auto closing should work in more situations
I20041221-0800 Angular Bracket auto closing does not work for a field type. In this example: void m() { HashMap hm= new HashMap(); ... ... an opening bracket < is - automatically closed when inserted between HashMap and () - not automatically closed when inserted between HashMap and hm. It should be closed in both cases.
org.eclipse.jdt.text.tests/src/org/eclipse/jdt/text/tests/BracketInserterTest.java
* @param stateMask the state mask
	 */
	private void type(char character, int keyCode, int stateMask) {
		Event event= new Event();
		event.character= character;
		event.keyCode= keyCode;
		event.stateMask= stateMask;
		fAccessor.invoke("handleKeyDown", new Object[] {event});
	}
	/**
	 * Type a character into the styled text and drive the event loop.
	 * 
	 * @param character the character to type
	 */
	private void typeAndRun(char character) {
		type(character);
		runEvents();
	}
	private int getCaret() {
		return ((ITextSelection) fEditor.getSelectionProvider().getSelection()).getOffset();
	}
	private void setCaret(int offset) {
		fEditor.getSelectionProvider().setSelection(new TextSelection(offset, 0));
	}
	private void runEvents() {
		while (fTextWidget.getDisplay().readAndDispatch()) {
		}
	}
}