public void test_LikeSearch_WildCard_variousChar_whiteOption() { // ## Arrange ## LikeSearchOption option = new LikeSearchOption(); option.escapeByPipeLine(); // ## Act & Assert ## assertEquals("ABC%CBA", option.generateRealValue("ABC%CBA")); assertEquals("ABC_CBA", option.generateRealValue("ABC_CBA")); assertEquals("ABC%CB|%A", option.generateRealValue("ABC%CB%A")); assertEquals("ABC_CB|_A", option.generateRealValue("ABC_CB_A")); assertEquals("ABC_C[]B|_A", option.generateRealValue("ABC_C[]B_A")); // ## Arrange ## DBWay dbway = DBCurrent.getInstance().currentDBDef().dbway(); option.acceptOriginalWildCardList(dbway.getOriginalWildCardList()); // ## Act & Assert ## assertEquals("ABC|%CBA", option.generateRealValue("ABC%CBA")); assertEquals("ABC|_CBA", option.generateRealValue("ABC_CBA")); assertEquals("ABC|%CB|%A", option.generateRealValue("ABC%CB%A")); assertEquals("ABC|_CB|_A", option.generateRealValue("ABC_CB_A")); assertEquals("ABC|_C[]B|_A", option.generateRealValue("ABC_C[]B_A")); }
// =================================================================================== // Current DBDef // ============= public DBDef getCurrentDBDef() { return DBCurrent.getInstance().currentDBDef(); }