Added tests for amazon data source
This commit is contained in:
@@ -188,4 +188,16 @@ class AmazonProductDataSourceTest {
|
|||||||
// Verify the exception message
|
// Verify the exception message
|
||||||
assertEquals("Couldn't fulfill Amazon API request", exception.getMessage());
|
assertEquals("Couldn't fulfill Amazon API request", exception.getMessage());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
void getDataOrigin_ReturnsExpectedDataOrigin() {
|
||||||
|
String dataOrigin = demoDataSource.getDataOrigin();
|
||||||
|
assertEquals(demoDataOrigin, dataOrigin);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Test
|
||||||
|
void getApiKey_ReturnsExpectedApiKey() {
|
||||||
|
String apiKey = demoDataSource.getApiKey();
|
||||||
|
assertEquals(demoApiKey, apiKey);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user