Get rid of the delete() method on ReservedList

It wasn't being used by any actual code, and having helper methods handling
saving/persistence on entities like this is not a pattern we want to encourage,
since it hides Datastore transactions from further up in the call chain. The
idea is that you can always look for ofy() calls in the same layer of code to
see where persisted data is being changed.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=143036027
This commit is contained in:
mcilwain 2016-12-27 09:17:01 -08:00 committed by Ben McIlwain
parent 28f6c770c8
commit 48a1bacbb0
2 changed files with 0 additions and 32 deletions

View file

@ -232,14 +232,6 @@ public class ReservedListTest {
assertThat(rl.isInUse()).isFalse();
}
@Test
public void testDelete() throws Exception {
persistReservedList("reserved", "trombone,FULLY_BLOCKED");
assertThat(ReservedList.get("reserved")).isPresent();
ReservedList.delete("reserved");
assertThat(ReservedList.get("reserved")).isAbsent();
}
@Test
public void testSetFromInputLines() throws Exception {
ReservedList reservedList = persistReservedList("reserved", "trombone,FULLY_BLOCKED");
@ -263,12 +255,6 @@ public class ReservedListTest {
assertThat(original.getReservedListEntries()).isEqualTo(clone.getReservedListEntries());
}
@Test
public void testDelete_failsWhenListDoesntExist() throws Exception {
thrown.expect(IllegalStateException.class);
ReservedList.delete("reserved");
}
@Test
public void testSave_badSyntax() throws Exception {
thrown.expect(IllegalArgumentException.class, "Could not parse line in reserved list");