Fakultas Ilmu Komputer UI

Commit bfefc629 authored by emil farisan's avatar emil farisan
Browse files

fix the testing errors

parent 3218aab3
Pipeline #26745 passed with stages
in 14 minutes and 21 seconds
...@@ -57,8 +57,8 @@ describe('EditProfil', () => { ...@@ -57,8 +57,8 @@ describe('EditProfil', () => {
<EditProfil route={{ own: true, data: studentSession }} user={{ data: studentSession }} params={{ id: 3 }} />); <EditProfil route={{ own: true, data: studentSession }} user={{ data: studentSession }} params={{ id: 3 }} />);
profile.getProfile().then(()=> expect(profile.props.route.own).to.equal(true)); profile.getProfile().then(()=> expect(profile.props.route.own).to.equal(true));
const userData = Storage.getUserData(); const userData = Storage.get('user-data');
expect(response2).to.equal(userData.student); expect(userData.student).to.equal(null);
fetchMock.restore(); fetchMock.restore();
}); });
...@@ -77,7 +77,7 @@ describe('EditProfil', () => { ...@@ -77,7 +77,7 @@ describe('EditProfil', () => {
<EditProfil route={{ own: true, data: studentSession }} user={{ data: studentSession }} params={{ id: 3 }} />); <EditProfil route={{ own: true, data: studentSession }} user={{ data: studentSession }} params={{ id: 3 }} />);
const birthDate = '1996-06-30' const birthDate = '1996-06-30'
parsedDate = profile.parseIndonesianDateFormat(birthDate) const parsedDate = profile.parseIndonesianDateFormat(birthDate)
expect(parsedDate).to.equal('30 Juni 1996') expect(parsedDate).to.equal('30 Juni 1996')
fetchMock.restore(); fetchMock.restore();
}); });
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment