Source:
<code>public void testAssetReportFilterSuccess() throws Exception { List<String> accessTokens = Arrays.asList(getItemCreateResponse().getAccessToken()); Response<AssetReportCreateResponse> createResponse = AssetReportCreateTest.createAssetReport(client(), accessTokens); String assetReportToken = createResponse.body().getAssetReportToken(); Response<AssetReportGetResponse> response = waitTillReady(client(), assetReportToken); AssetReportGetResponse respBody = response.body(); assertSuccessResponse(response); assertNotNull(respBody.getReport()); assertNotNull(respBody.getReport().getUser()); assertFalse(respBody.getReport().getItems().isEmpty()); assertNotNull(respBody.getReport().getAssetReportId()); List<String> accountIdsToExclude = new ArrayList<>(); accountIdsToExclude.add(respBody.getReport().getItems().get(0).getAccounts().get(0).getAccountId()); AssetReportFilterRequest assetReportFilterRequest = new AssetReportFilterRequest(assetReportToken, accountIdsToExclude); Response<AssetReportCreateResponse> assetReportFilterResponse = filterAssetReport(assetReportFilterRequest); String assetReportFilterToken = assetReportFilterResponse.body().getAssetReportToken(); Response<AssetReportGetResponse> filteredReportResponse = waitTillReady(client(), assetReportFilterToken); <START> assertEquals(getAssetReportAccountIds(respBody.getReport()).size() - 1, <END> getAssetReportAccountIds(filteredReportResponse.body().getReport()).size()); }</code><technical_language>assert exact tokens well? size</technical_language>

Target:
public void testAssetReportFilterSuccess() throws Exception { List<String> accessTokens = Arrays.asList(getItemCreateResponse().getAccessToken()); Response<AssetReportCreateResponse> createResponse = AssetReportCreateTest.createAssetReport(client(), accessTokens); String assetReportToken = createResponse.body().getAssetReportToken(); Response<AssetReportGetResponse> response = waitTillReady(client(), assetReportToken); AssetReportGetResponse respBody = response.body(); assertSuccessResponse(response); assertNotNull(respBody.getReport()); assertNotNull(respBody.getReport().getUser()); assertFalse(respBody.getReport().getItems().isEmpty()); assertNotNull(respBody.getReport().getAssetReportId()); List<String> accountIdsToExclude = new ArrayList<>(); accountIdsToExclude.add(respBody.getReport().getItems().get(0).getAccounts().get(0).getAccountId()); AssetReportFilterRequest assetReportFilterRequest = new AssetReportFilterRequest(assetReportToken, accountIdsToExclude); Response<AssetReportCreateResponse> assetReportFilterResponse = filterAssetReport(assetReportFilterRequest); String assetReportFilterToken = assetReportFilterResponse.body().getAssetReportToken(); Response<AssetReportGetResponse> filteredReportResponse = waitTillReady(client(), assetReportFilterToken); Set<String> filteredAssetReportIds = getAssetReportAccountIds(filteredReportResponse.body().getReport()); Set<String> unfilteredAssetReportIds = getAssetReportAccountIds(respBody.getReport()); assertEquals(unfilteredAssetReportIds.size() - 1, filteredAssetReportIds.size()); filteredAssetReportIds.add(accountIdsToExclude.get(0)); assertEquals(unfilteredAssetReportIds, filteredAssetReportIds); }