Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/7-add-put-restaurant' into 7-add…
Browse files Browse the repository at this point in the history
…-put-restaurant

# Conflicts:
#	frontend/src/components/RestaurantForm/RestaurantForm.component.test.tsx
  • Loading branch information
gcode-de committed Jun 5, 2024
2 parents b23239c + 1290507 commit 74691bc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,13 @@ test('RestaurantForm component displays input field "city"', () => {
expect(cityInput).toBeInTheDocument();
});

test('RestaurantForm component displays "add" button', () => {
test('RestaurantForm component displays "save" button', () => {
render(
<MemoryRouter>
<RestaurantForm onSubmit={jest.fn()} restaurantData={null}/>
</MemoryRouter>);
const addButton = screen.getByRole("button", {
name: /add/i
name: /save/i
});
expect(addButton).toBeInTheDocument();
});
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/RestaurantForm/RestaurantForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export default function RestaurantForm({restaurantData, onSubmit}:RestaurantForm
<StyledFieldError>{fieldValidation.city}</StyledFieldError>
</StyledFormRow>
</StyledFormBody>
<button type="submit">Add</button>
<button type="submit">Save</button>
</StyledForm>
)
}

0 comments on commit 74691bc

Please sign in to comment.