@Test
public void testGetNestedFieldsWithQueryParameter() throws IOException {

	Product product = _toProduct(1L, null);
	Mockito.when(
		_writerInterceptorContext.getEntity()
	).thenReturn(
		product
	);
	Mockito.doReturn(
		new NestedFieldsHttpServletRequestWrapperTest.
			MockHttpServletRequest("productOptions")
	).when(
		_nestedFieldServiceTrackerCustomizer
	).getHttpServletRequest(
		Mockito.any(Message.class)
	);
	MultivaluedHashMap<String, String> queryParameters =
		new MultivaluedHashMap<String, String>() {
			{
				putSingle(
					"productOptions.createDate",
					"2019-02-19T08:03:11.763Z");
				putSingle("productOptions.name", "test2");
			}
		};
	NestedFieldsContextThreadLocal.setNestedFieldsContext(
		new NestedFieldsContext(
			Collections.singletonList("productOptions"), new MessageImpl(),
			_getPathParameters(), "v1.0", queryParameters));
	_nestedFieldsWriterInterceptor.aroundWriteTo(_writerInterceptorContext);
	ProductOption[] productOptions = product.getProductOptions();
	Assert.assertEquals(
		Arrays.toString(productOptions), 1, productOptions.length);
	ProductOption productOption = productOptions[0];
	Assert.assertEquals("test2", productOption.getName());
}