Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[swtbot-dev] testing content assist on a text field

Hi

I had started a discussion about this subject in SWTBot forum,
https://www.eclipse.org/forums/index.php/t/816232/, and Mickael
suggested to move it here

from what I understand there's no way of testing the content assist on a
Text field, is it?

Something like autoCompleteProposal in SWTBotEditor.

This would be useful to test content assist on a Text field that you can
add with a org.eclipse.jface.fieldassist.ContentProposalAdapter, e.g.,

new ContentProposalAdapter
	(text, new TextContentAdapter(),
		new SimpleContentProposalProvider(...),
		keyStroke,
		null);

For the moment, in one of our tests,
http://git.eclipse.org/c/emf-parsley/org.eclipse.emf-parsley.git/tree/tests/org.eclipse.emf.parsley.tests.swtbot/src/org/eclipse/emf/parsley/tests/EmfParsleyFormTests.java
I managed to test it by adapting code from SWTBotEditor... I think it
would be useful to have it in SWTBotText (just like in SWTBotEditor)
since it's not that trivial to test it.

any thoughts?

cheers
	Lorenzo

-- 
Lorenzo Bettini, PhD in Computer Science, DI, Univ. Torino
HOME: http://www.lorenzobettini.it
Xtext Book:
http://www.packtpub.com/implementing-domain-specific-languages-with-xtext-and-xtend/book




Back to the top