public void testParseComplexName() {
// Mock up a spreadsheet to match the critical details of the sample
HSSFWorkbook wb = new HSSFWorkbook();
wb.createSheet("Sheet1");
HSSFName definedName = wb.createName();
definedName.setNameName("foo");
definedName.setRefersToFormula("Sheet1!B2");
// Set the complex flag - POI doesn't usually manipulate this flag
NameRecord nameRec = TestHSSFName.getNameRecord(definedName);