Search in sources :

Example 6 with AbstractSQLProvider

use of com.google.security.zynamics.binnavi.Database.AbstractSQLProvider in project binnavi by google.

the class PostgreSQLProviderTest method testCProjectFunctionsgetViewsWithAddresses1.

@Test
public void testCProjectFunctionsgetViewsWithAddresses1() throws CouldntLoadDataException, LoadCancelledException {
    final INaviProject project = getProvider().loadProjects().get(0);
    project.load();
    final IFilledList<UnrelocatedAddress> addresses = new FilledList<UnrelocatedAddress>();
    List<INaviView> views = PostgreSQLProjectFunctions.getViewsWithAddresses((AbstractSQLProvider) getProvider(), project, addresses, true);
    assertEquals(0, views.size());
    addresses.add(new UnrelocatedAddress(new CAddress(0x10033DCL)));
    views = PostgreSQLProjectFunctions.getViewsWithAddresses((AbstractSQLProvider) getProvider(), project, addresses, true);
    assertEquals(0, views.size());
    addresses.add(new UnrelocatedAddress(new CAddress(0x1003429)));
    views = PostgreSQLProjectFunctions.getViewsWithAddresses((AbstractSQLProvider) getProvider(), project, addresses, true);
    assertEquals(0, views.size());
    views = PostgreSQLProjectFunctions.getViewsWithAddresses((AbstractSQLProvider) getProvider(), project, addresses, false);
    assertEquals(0, views.size());
}
Also used : AbstractSQLProvider(com.google.security.zynamics.binnavi.Database.AbstractSQLProvider) INaviProject(com.google.security.zynamics.binnavi.disassembly.INaviProject) INaviView(com.google.security.zynamics.binnavi.disassembly.views.INaviView) IFilledList(com.google.security.zynamics.zylib.types.lists.IFilledList) FilledList(com.google.security.zynamics.zylib.types.lists.FilledList) UnrelocatedAddress(com.google.security.zynamics.binnavi.disassembly.UnrelocatedAddress) CAddress(com.google.security.zynamics.zylib.disassembly.CAddress) ExpensiveBaseTest(com.google.security.zynamics.binnavi.disassembly.types.ExpensiveBaseTest) Test(org.junit.Test)

Aggregations

AbstractSQLProvider (com.google.security.zynamics.binnavi.Database.AbstractSQLProvider)6 ExpensiveBaseTest (com.google.security.zynamics.binnavi.disassembly.types.ExpensiveBaseTest)6 Test (org.junit.Test)6 CConnection (com.google.security.zynamics.binnavi.Database.CConnection)4 UnrelocatedAddress (com.google.security.zynamics.binnavi.disassembly.UnrelocatedAddress)2 INaviView (com.google.security.zynamics.binnavi.disassembly.views.INaviView)2 CAddress (com.google.security.zynamics.zylib.disassembly.CAddress)2 FilledList (com.google.security.zynamics.zylib.types.lists.FilledList)2 IFilledList (com.google.security.zynamics.zylib.types.lists.IFilledList)2 INaviModule (com.google.security.zynamics.binnavi.disassembly.INaviModule)1 INaviProject (com.google.security.zynamics.binnavi.disassembly.INaviProject)1