Commit 560b6a97 authored by Greg Williams's avatar Greg Williams
Browse files

Updated to use new java simulator admin API. Reenabled overlapped PUT test....

Updated to use new java simulator admin API. Reenabled overlapped PUT test. Fixed simulator shutdown.
parent 3b98f638
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -170,7 +170,7 @@ namespace :java_sim do

  def java_sim_erase_drive
    java_sim_start
    sh "#{JAVA_BIN} -classpath #{ENV['CLASSPATH']} com.seagate.kinetic.admin.cli.KineticAdminCLI -setup -erase true"
    sh "\"#{JAVA_BIN}\" -classpath \"#{ENV['CLASSPATH']}\" com.seagate.kinetic.admin.cli.KineticAdminCLI -instanterase"
  end

  def java_sim_cleanup
+0 −46
Original line number Diff line number Diff line
@@ -63,52 +63,6 @@ void SystemTestSetup(SystemTestFixture* fixture)
    //     " operation w/session!");
}

void SystemTestEraseSimulator(SystemTestFixture* fixture)
{ LOG_LOCATION;
    TEST_ASSERT_NOT_NULL_MESSAGE(fixture, "System test fixture is NULL!");
    if (fixture->keyToDelete.bytesUsed > 0) {
        char verData[] = "v1.0";
        ByteBuffer ver = ByteBuffer_Create((uint8_t*)verData, strlen(verData), strlen(verData));
        KineticEntry entry = {
            .key = fixture->keyToDelete,
            .dbVersion = ver,
        };
        KineticStatus status = KineticClient_Delete(fixture->handle, &entry);
        if (status != KINETIC_STATUS_SUCCESS) {
            LOG("Failed to delete object via specified key!");
        }
        else {
            LOG("DELETED!");
        }

        verData[1] = '2';
        entry = (KineticEntry) {
            .key = fixture->keyToDelete,
            .dbVersion = ver,
        };
        status = KineticClient_Delete(fixture->handle, &entry);
        if (status != KINETIC_STATUS_SUCCESS) {
            LOG("Failed to delete object via specified key!");
        }
        else {
            LOG("NOTHING DELETED!");
        }

        verData[1] = '3';
        entry = (KineticEntry) {
            .key = fixture->keyToDelete,
            .dbVersion = ver,
        };
        status = KineticClient_Delete(fixture->handle, &entry);
        if (status != KINETIC_STATUS_SUCCESS) {
            LOG("Failed to delete object via specified key!");
        }
        else {
            LOG("NOTHING DELETED!");
        }
    }
}

void SystemTestTearDown(SystemTestFixture* fixture)
{
    TEST_ASSERT_NOT_NULL_MESSAGE(fixture, "System test fixture is NULL!");
+0 −1
Original line number Diff line number Diff line
@@ -35,7 +35,6 @@ typedef struct _SystemTestFixture {
} SystemTestFixture;

void SystemTestSetup(SystemTestFixture* fixture);
void SystemTestEraseSimulator(SystemTestFixture* fixture);
void SystemTestTearDown(SystemTestFixture* fixture);
void SystemTestSuiteTearDown(SystemTestFixture* fixture);

+0 −1
Original line number Diff line number Diff line
@@ -83,7 +83,6 @@ void setUp(void)
    ByteBuffer_AppendCString(&ValueBuffer, "lorem ipsum... blah blah blah... etc.");

    ByteBuffer_Append(&Fixture.keyToDelete, Key.data, KeyBuffer.bytesUsed);
    SystemTestEraseSimulator(&Fixture);
}

void tearDown(void)
+0 −1
Original line number Diff line number Diff line
@@ -79,7 +79,6 @@ void setUp(void)
    ByteBuffer_AppendArray(&ValueBuffer, TestValue);

    ByteBuffer_Append(&Fixture.keyToDelete, Key.data, KeyBuffer.bytesUsed);
    SystemTestEraseSimulator(&Fixture);

    // Setup to write some test data
    KineticEntry putEntry = {
Loading