diff options
| author | Erik Larkö <erik@mullvad.net> | 2017-09-25 11:32:46 +0200 |
|---|---|---|
| committer | Erik Larkö <erik@mullvad.net> | 2017-09-25 15:22:45 +0200 |
| commit | 7ad09bb75de84957a70014c9e4aa90f4c624a2da (patch) | |
| tree | acad5ea45c6ce3a34d8a2bf6bc76d3e2569a0d30 /test/components | |
| parent | 6ffac7518b1c19cbaa19800456134cc769891783 (diff) | |
| download | mullvadvpn-7ad09bb75de84957a70014c9e4aa90f4c624a2da.tar.xz mullvadvpn-7ad09bb75de84957a70014c9e4aa90f4c624a2da.zip | |
Read the city and coutry from the temporary config until we implement it in the backend
Diffstat (limited to 'test/components')
| -rw-r--r-- | test/components/Connect.spec.js | 24 |
1 files changed, 18 insertions, 6 deletions
diff --git a/test/components/Connect.spec.js b/test/components/Connect.spec.js index 30228fc4c6..e116311e42 100644 --- a/test/components/Connect.spec.js +++ b/test/components/Connect.spec.js @@ -36,9 +36,15 @@ describe('components/Connect', () => { }); it('shows the connection location information when connected', () => { - const component = renderConnected({}, { - country: 'sweden', - city: 'gothenburg', + const component = renderConnected({ + getServerInfo: (_s) => ({ + address: '', + name: '', + location: [0, 0], + country: 'sweden', + city: 'gothenburg', + }), + }, { clientIp: '1.2.3.4', }); const countryAndCity = component.find('.connect__status-location'); @@ -50,9 +56,15 @@ describe('components/Connect', () => { }); it('shows the connection location information when disconnected', () => { - const component = renderNotConnected({}, { - country: 'sweden', - city: 'gothenburg', + const component = renderNotConnected({ + getServerInfo: (_s) => ({ + address: '', + name: '', + location: [0, 0], + country: 'sweden', + city: 'gothenburg', + }), + }, { clientIp: '1.2.3.4', }); const countryAndCity = component.find('.connect__status-location'); |
