-
Notifications
You must be signed in to change notification settings - Fork 4
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
#161966567 Signup New Users #14
Conversation
8759bce
to
7177777
Compare
7177777
to
5cfc276
Compare
5cfc276
to
cbd62bb
Compare
cbd62bb
to
51816e3
Compare
51816e3
to
3f7429c
Compare
3f7429c
to
b23e168
Compare
b23e168
to
d6189cf
Compare
src/reducers/registrationReducer.js
Outdated
export default function registrationReducer(state = initialState, action) { | ||
switch (action.type) { | ||
case types.USER_REGISTRATION_SUBMIT: | ||
return Object.assign({}, state, { action: action.registrationData, loading: true }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use the spread operator
instead of Object.assign
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed to use the spread operator
const wrapper = mount(<BrowserRouter><RegistrationPage {...props} /></BrowserRouter>); | ||
const submitButton = wrapper.find('#submit').last(); | ||
expect(wrapper.find('#submit').exists()).toBe(true); | ||
submitButton.simulate('click'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is being tested here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I edited the test
|
||
describe('Registration Page class Methods', () => { | ||
it('formatUserData Function', () => { | ||
const setupProps = Object.assign({}, props, { actions: {}}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of using Object.assign
add actions to the props object and pass the props to the component instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good job. Please address the requested changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix the requested changes
d6189cf
to
8a9a0c5
Compare
8a9a0c5
to
83332f5
Compare
83332f5
to
c708800
Compare
I have made the requested changes. |
@actlikewill You have not added me and Timothy as your reviewers |
Sorry about that ... I have done so now, kindly review |
c708800
to
932c343
Compare
- allows user to create a new account [#161966567]
932c343
to
2fb3dd5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work @actlikewill
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks okey and everything is working well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
What does this pull request do?
using their email and username.
Description of the tasks to be completed?
How should this be manually tested?
clone the repo
https://github.com/andela/ah-technocrats-frontend.git
change to the cloned directory
cd ah-technocrats-frontend
git checkout ft-registration-161966567
to checkout to this branchrun
npm install
to install the application.run npm start
To log in, Enter your username and email and a password.
The form will validate the entries according to the data provided. The following are the validations present:
Screenshots
The form displaying all the errors
![screen shot 2019-01-18 at 09 35 52](https://user-images.githubusercontent.com/25079238/51369407-86fc1f80-1b04-11e9-902b-5a3ca7caab55.png)
What are the relevant Pivotal Tracker Stories
#161966567
Checklist: