Chapter 5. Managing and Testing User Messages

In Java, we use resource bundles to store the text that is presented in our user interfaces. This has a number of benefits. For example, it is then very easy to produce localized versions of our software. In this chapter, we introduce a system of managing and testing resource bundles that achieves two important goals.

First, we will be able to thoroughly unit test our resource bundles. This eliminates a lot of mistakes that would otherwise be found only with laborious manual testing.

Second, we will ensure that keyboard shortcuts can be used to activate all of our components. This is an important aspect of usability, and keyboard shortcuts are the way we will be activating our components in automated ...

Get Swing Extreme Testing now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.