Rename Event

Was conflicting with an Event defined in fdbclient, and due to how the unit
tests are currently built, fdb_c includes fdbclient as a dependency.
This commit is contained in:
Lukas Joswiak 2020-10-08 11:09:23 -07:00
parent 1deea78dac
commit 805a8f5909
1 changed files with 4 additions and 4 deletions

View File

@ -212,7 +212,7 @@ void clear_data(FDBDatabase *db) {
insert_data(db, {});
}
struct Event {
struct FdbEvent {
void wait() {
std::unique_lock<std::mutex> l(mutex);
cv.wait(l, [this]() { return this->complete; });
@ -233,7 +233,7 @@ TEST_CASE("fdb_future_set_callback") {
fdb::Transaction tr(db);
fdb::ValueFuture f1 = tr.get((const uint8_t *)"foo", 3, /*snapshot*/ true);
struct Context {
Event event;
FdbEvent event;
};
Context context;
fdb_check(f1.set_callback(+[](FDBFuture *f1, void *param) {
@ -1478,7 +1478,7 @@ TEST_CASE("fdb_transaction_watch") {
fdb::Transaction tr(db);
struct Context {
Event event;
FdbEvent event;
};
Context context;
@ -1524,7 +1524,7 @@ TEST_CASE("block_from_callback") {
fdb::Transaction tr(db);
fdb::ValueFuture f1 = tr.get((const uint8_t *)"foo", 3, /*snapshot*/ true);
struct Context {
Event event;
FdbEvent event;
fdb::Transaction *tr;
};
Context context;