Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SNAP-3771_SNAP-3772_SNAP-3773_SNAP-3774_SNAP-3775_product_library #475

Open
wants to merge 4 commits into
base: 11.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,11 @@
*/
public final class RepositoriesCredentialsPersistence {

public static final byte VISIBLE_PRODUCTS_PER_PAGE = 20;
public static final byte VISIBLE_PRODUCTS_PER_PAGE = 10;

public static final boolean UNCOMPRESSED_DOWNLOADED_PRODUCTS = false;

public static final boolean DOWNLOAD_ALL_PAGES = true;
public static final boolean DOWNLOAD_ALL_PAGES = false;

/**
* The pattern for remote repository.
Expand Down
2 changes: 1 addition & 1 deletion snap-remote-products-repository/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
<description>The Remote Products Repository allows downloading the products from a list of repositories.</description>

<properties>
<tao.version>1.5.0</tao.version>
<tao.version>1.5.2</tao.version>
</properties>

<dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -349,8 +349,7 @@ public static List<RepositoryQueryParameter> getMissionParameters(String dataSou
}
boolean required = param.isRequired();
if (!required) {
if (param.getName().equals(CommonParameterNames.PLATFORM) || param.getName().equals(CommonParameterNames.START_DATE)
|| param.getName().equals(CommonParameterNames.END_DATE) || param.getName().equals(CommonParameterNames.FOOTPRINT)) {
if (param.getName().equals(CommonParameterNames.PLATFORM)) {

required = true;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
import java.util.List;
import java.util.Map;

import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;

Expand Down Expand Up @@ -56,7 +57,7 @@ private static void downloadRepositoryProviderProductList(Credentials credential
}
List<RepositoryQueryParameter> missionParameters = repositoryProvider.getMissionParameters(mission);
assertNotNull(missionParameters);
assertTrue(missionParameters.size() > 0);
assertFalse(missionParameters.isEmpty());

List<RepositoryProduct> remoteProducts = repositoryProvider.downloadProductList(credentials, mission, 100, parameterValues, downloaderListener, threadStatus);
assertNotNull(remoteProducts);
Expand Down Expand Up @@ -197,18 +198,11 @@ private void testGetRemoteProductsRepositoryProvider(RemoteProductsRepositoryPro
assertNotNull(queryParameters);
assertTrue(queryParameters.size() >= 3);

RepositoryQueryParameter parameter = findQueryParameterByName("footprint", queryParameters);
if (parameter != null) {
assertTrue(parameter.isRequired());
}

parameter = findQueryParameterByName("startDate", queryParameters);
RepositoryQueryParameter parameter = findQueryParameterByName("startDate", queryParameters);
assertNotNull(parameter);
assertTrue(parameter.isRequired());

parameter = findQueryParameterByName("endDate", queryParameters);
assertNotNull(parameter);
assertTrue(parameter.isRequired());
}
}

Expand Down