This commit is contained in:
Hillel Coren 2019-08-23 08:38:18 +03:00
parent b991d3a40b
commit ae732e41b1
2 changed files with 8 additions and 7 deletions

View File

@ -13,8 +13,7 @@ AppState appReducer(AppState state, dynamic action) {
if (action is UserLogout) {
return AppState().rebuild((b) => b
..authState.replace(state.authState)
..uiState.enableDarkMode =
state.uiState.enableDarkMode || state.uiState.isTesting
..uiState.enableDarkMode = state.uiState.enableDarkMode
..uiState.isTesting = state.uiState.isTesting);
} else if (action is LoadStateSuccess) {
return action.state.rebuild((b) => b

View File

@ -89,11 +89,13 @@ void main() {
// Edit the newly created product
test('Edit an existing product', () async {
print('Select product: $productKey');
await driver.scrollUntilVisible(
find.byType('ListView'), find.text(productKey),
dyScroll: -300);
await driver.tap(find.text(productKey));
if (await isMobile(driver)) {
print('Select product: $productKey');
await driver.scrollUntilVisible(
find.byType('ListView'), find.text(productKey),
dyScroll: -300);
await driver.tap(find.text(productKey));
}
print('Tap edit');
await driver.tap(find.text(localization.edit));