Fix: random text (e.g. <dagger|sword>) didn't work with <1|2|3> - fixes #303.  Also added tests to help prevent future issues.