use of com.alibaba.druid.wall.spi.SQLServerWallProvider in project druid by alibaba.
the class WallStatTest_select_2 method testSQLServer.
public void testSQLServer() throws Exception {
WallProvider provider = new SQLServerWallProvider();
assertTrue(provider.checkValid(sql));
}
use of com.alibaba.druid.wall.spi.SQLServerWallProvider in project druid by alibaba.
the class WallStatTest_create_table method testSQLServer.
public void testSQLServer() throws Exception {
WallProvider provider = new SQLServerWallProvider();
provider.getConfig().setCreateTableAllow(true);
Assert.assertTrue(provider.checkValid(sql));
WallTableStat tableStat = provider.getTableStat("t");
Assert.assertEquals(1, tableStat.getCreateCount());
}
use of com.alibaba.druid.wall.spi.SQLServerWallProvider in project druid by alibaba.
the class WallStatTest_insert method testSQLServer.
public void testSQLServer() throws Exception {
WallProvider provider = new SQLServerWallProvider();
Assert.assertTrue(provider.checkValid(sql));
WallTableStat tableStat = provider.getTableStat("t");
Assert.assertEquals(1, tableStat.getInsertCount());
}
use of com.alibaba.druid.wall.spi.SQLServerWallProvider in project druid by alibaba.
the class WallStatTest_select_1 method testSQLServer.
public void testSQLServer() throws Exception {
WallProvider provider = new SQLServerWallProvider();
Assert.assertTrue(provider.checkValid(sql));
{
WallTableStat tableStat = provider.getTableStat("lhwbbs_posts_reply");
Assert.assertEquals(1, tableStat.getSelectCount());
}
{
WallTableStat tableStat = provider.getTableStat("lhwbbs_posts");
Assert.assertEquals(1, tableStat.getSelectCount());
}
}
use of com.alibaba.druid.wall.spi.SQLServerWallProvider in project druid by alibaba.
the class WallStatTest_update method testSQLServer.
public void testSQLServer() throws Exception {
WallProvider provider = new SQLServerWallProvider();
Assert.assertTrue(provider.checkValid(sql));
WallTableStat tableStat = provider.getTableStat("t");
Assert.assertEquals(1, tableStat.getUpdateCount());
}
Aggregations