@Test public void convertIdentifyingTokenListVerifyReturnValue() { ImmutableSet<IdentifyingToken> identifyingTokens = ImmutableSet.<IdentifyingToken>builder() .add(IDENTIFYING_TOKEN_ACCEPTED) .add(IDENTIFYING_TOKEN_BLOCKED) .add(IDENTIFYING_TOKEN_DELETED) .add(IDENTIFYING_TOKEN) .build(); Set<AuthorisationData> authorisationDataList = service.convertIdentifyingTokenList(identifyingTokens); Assert.assertEquals(identifyingTokens.size(), authorisationDataList.size()); }
public Set<AuthorisationData> convertIdentifyingTokenList(Set<IdentifyingToken> tokens) { Set<AuthorisationData> resultList = new HashSet<>(); for (IdentifyingToken token : tokens) { resultList.add(convertIdentifyingToken(token)); } return resultList; }
IdentifyingTokenConverterService { public Set<AuthorisationData> convertIdentifyingTokenList(Set<IdentifyingToken> tokens) { Set<AuthorisationData> resultList = new HashSet<>(); for (IdentifyingToken token : tokens) { resultList.add(convertIdentifyingToken(token)); } return resultList; } }
IdentifyingTokenConverterService { public Set<AuthorisationData> convertIdentifyingTokenList(Set<IdentifyingToken> tokens) { Set<AuthorisationData> resultList = new HashSet<>(); for (IdentifyingToken token : tokens) { resultList.add(convertIdentifyingToken(token)); } return resultList; }  }
IdentifyingTokenConverterService { public Set<AuthorisationData> convertIdentifyingTokenList(Set<IdentifyingToken> tokens) { Set<AuthorisationData> resultList = new HashSet<>(); for (IdentifyingToken token : tokens) { resultList.add(convertIdentifyingToken(token)); } return resultList; }  Set<AuthorisationData> convertIdentifyingTokenList(Set<IdentifyingToken> tokens); AuthorisationData convertIdentifyingToken(IdentifyingToken token); }
IdentifyingTokenConverterService { public Set<AuthorisationData> convertIdentifyingTokenList(Set<IdentifyingToken> tokens) { Set<AuthorisationData> resultList = new HashSet<>(); for (IdentifyingToken token : tokens) { resultList.add(convertIdentifyingToken(token)); } return resultList; }  Set<AuthorisationData> convertIdentifyingTokenList(Set<IdentifyingToken> tokens); AuthorisationData convertIdentifyingToken(IdentifyingToken token);  }