use of com.google.firebase.database.FirebaseDatabase in project SEProject by NicholasBarreyre.
the class MapsActivityUnitTests method teardownTestLoc.
@AfterClass
public static void teardownTestLoc() {
FirebaseDatabase db = FirebaseDatabase.getInstance();
DatabaseReference myRef = db.getReference("user_locations");
myRef.child(TEST_FRIEND).setValue(null);
}
use of com.google.firebase.database.FirebaseDatabase in project SEProject by NicholasBarreyre.
the class TestingHelper method resetTestUserGoals.
/**
* Test helper to reset the testuser's goals list
*/
public static void resetTestUserGoals() {
FirebaseDatabase database = FirebaseDatabase.getInstance();
DatabaseReference usersReference = database.getReference("users/testuser");
usersReference.child("userGoals").setValue(null);
}
use of com.google.firebase.database.FirebaseDatabase in project SEProject by NicholasBarreyre.
the class TestingHelper method resetTestTeam.
public static void resetTestTeam() {
FirebaseDatabase database = FirebaseDatabase.getInstance();
DatabaseReference teamsReference = database.getReference("teams");
teamsReference.child("testteam").setValue(null);
}
use of com.google.firebase.database.FirebaseDatabase in project SEProject by NicholasBarreyre.
the class TestingHelper method addTestUserExercises.
/**
* Test helper to add test exercises to testuser
*/
public static void addTestUserExercises() {
FirebaseDatabase database = FirebaseDatabase.getInstance();
DatabaseReference usersReference = database.getReference("users/testuser");
ArrayList<Exercise> testExercises = new ArrayList<>();
testExercises.add(testExercise1);
testExercises.add(testExercise2);
testExercises.add(testExercise3);
usersReference.child("userExercises").setValue(testExercises);
}
use of com.google.firebase.database.FirebaseDatabase in project SEProject by NicholasBarreyre.
the class TestingHelper method resetTestUserWorkouts.
/**
* Test helper to reset the testuser's workout list
*/
public static void resetTestUserWorkouts() {
FirebaseDatabase database = FirebaseDatabase.getInstance();
DatabaseReference usersReference = database.getReference("users/testuser");
usersReference.child("userWorkouts").setValue(null);
}
Aggregations