make x default in compact form, remove unused endpoint from legacy controller, add compact forms to channel details

This commit is contained in:
Carsten Otto
2021-11-22 17:33:03 +01:00
parent 76628d0ce4
commit e03ecddf48
7 changed files with 35 additions and 36 deletions

View File

@@ -16,8 +16,6 @@ import java.util.Set;
import static de.cotto.lndmanagej.model.ChannelIdFixtures.CHANNEL_ID;
import static de.cotto.lndmanagej.model.ChannelIdFixtures.CHANNEL_ID_3;
import static de.cotto.lndmanagej.model.ChannelIdFixtures.CHANNEL_ID_COMPACT;
import static de.cotto.lndmanagej.model.ChannelIdFixtures.CHANNEL_ID_COMPACT_3;
import static de.cotto.lndmanagej.model.CoopClosedChannelFixtures.CLOSED_CHANNEL;
import static de.cotto.lndmanagej.model.CoopClosedChannelFixtures.CLOSED_CHANNEL_3;
import static de.cotto.lndmanagej.model.ForceClosingChannelFixtures.FORCE_CLOSING_CHANNEL;
@@ -74,13 +72,6 @@ class LegacyControllerIT {
.andExpect(content().string(CHANNEL_ID + "\n" + CHANNEL_ID_3));
}
@Test
void getOpenChannelIdsCompact() throws Exception {
when(channelService.getOpenChannels()).thenReturn(Set.of(LOCAL_OPEN_CHANNEL, LOCAL_OPEN_CHANNEL_3));
mockMvc.perform(get("/legacy/open-channels/compact"))
.andExpect(content().string(CHANNEL_ID_COMPACT + "\n" + CHANNEL_ID_COMPACT_3));
}
@Test
void getOpenChannelIdsPretty() throws Exception {
when(channelService.getOpenChannels()).thenReturn(Set.of(LOCAL_OPEN_CHANNEL, LOCAL_OPEN_CHANNEL_3));