239 Commits

Author SHA1 Message Date
Veeck
6e80e5a295
Add option to show hourly forecast in increments (#2998)
Adds new config option to show weather forecast for every X hour
(default value is 1 which reflects the current behaviour)
Also adds tests for hourly forecast
Fixes #2996

Co-authored-by: veeck <michael@veeck.de>
2023-01-10 18:55:07 +01:00
Veeck
a2624442cc
Cleanup compliments module (#2965)
Lots of small fixes and cleanups:
- only render something when there is a compliment
- cleanup naming
- use es6 notations
- use fetch instead of XMLHttpRequest in compliments

Co-authored-by: veeck <michael@veeck.de>
Co-authored-by: Karsten Hassel <hassel@gmx.de>
2022-12-10 21:23:00 +01:00
Veeck
3879949f58
Switch back to third party fetch lib for all node versions (#2961)
As discussed in https://github.com/MichMich/MagicMirror/pull/2952

Co-authored-by: veeck <michael@veeck.de>
2022-10-29 23:10:25 +02:00
buxxi
f25abfd2f8
Make the e2e tests wait for the app to start and close before running next test (#2952)
When trying to debug why the tests broke for
https://github.com/MichMich/MagicMirror/pull/2946 I found that the tests
does not wait for the app to start and close. So if the startup isn't
blocking that would fail.

So I added a callback for `close()` too and converted them to promises
for the `startApplication()` and `stopApplication()` and updated all the
e2e tests to await both. Will try to refactor all these callbacks to
promises in a later PR.
2022-10-29 22:34:17 +02:00
Veeck
2d3940a4ff
Use metric units internally in all weatherproviders (#2849)
So finally I think this refactorin is ready to be reviewed :-)

DONE:
- [x] Removed all conversion functions for wind and temperature from
specific weatherproviders
- [x] Use internally only metric units: celsius for temperature, meters
per seconds for wind
- [x] Convert temp and wind into the configured units when displaying
data on the UI
- [x] look how beaufort calculation uses metrics, added knots as new
windunit
- [x] add more e2e tests 

Checked providers:
- [x] Darksky
- [x] EnvCanada
- [x] OpenWeatherMap
- [x] SMHI provider 
- [x] UK Met Office
- [x] UK Met Office DataHub
- [x] WeatherBit
- [x] WeatherFlow
- [x] WeatherGov

TODO in different tickets:
- check weatherproviders for usage of weatherEndpoint (as seen in
https://github.com/MichMich/MagicMirror-Documentation/issues/131) -> see
#2926
- cleanup precipations -> #2953

Co-authored-by: veeck <michael@veeck.de>
2022-10-24 19:41:34 +02:00
Karsten Hassel
ad4dbd786a
added new electron tests supporting date mocking (#2947)
first PR for #2942 

- added new electron tests for calendar which test new css classes from
https://github.com/MichMich/MagicMirror/pull/2939
- moved some compliments tests from `e2e` to `electron` because of date
mocking
- removed mock stuff from compliments module
2022-10-17 07:20:23 +02:00
Veeck
a328ce537f
Cleanup test directory (#2937)
Moves files around and renames some so that the structure is cleaner and
more consistent
2022-10-07 12:16:37 -05:00
Veeck
ce4906d13b
Add test in compliments module for remotFile option (#2932)
nothing fancy here, just a simple test after @khassel's changes to the
test setup :-)

Co-authored-by: veeck <michael@veeck.de>
2022-10-04 14:26:31 +02:00
Karsten Hassel
f04d578704
improve tests (#2923)
use es6 syntax in all tests, split weather tests, remove callbacks
2022-10-04 10:15:24 +02:00
Karsten Hassel
0c1abad9df fix calendar_test_recurring.ics and uncomment recurring tests 2022-09-21 21:01:43 +02:00
Karsten Hassel
fb96cc3c72 fix e2e tests not failing on errors, disable recurring-event-tests of calendar 2022-09-21 00:28:43 +02:00
Mike Bishop
0c1e5ea881 Use German as the base for tests 2022-07-25 18:23:27 -04:00
Karsten Hassel
ae72ed8c67 improve startApplication 2022-05-27 21:49:29 +02:00
Karsten Hassel
0023c64d59 use internal fetch function of node instead external node-fetch library if node version >= v18 2022-05-27 19:46:28 +02:00
Kristjan SCHMIDT
6f27e5ae07 MagicMirror -> MagicMirror² 2022-01-26 23:47:51 +01:00
Kristjan SCHMIDT
a5668b1b99 Magic Mirror -> MagicMirror²
Consistent spelling
2022-01-26 23:09:26 +01:00
Karsten Hassel
82bb2544de add CHANGELOG and fix weather_spec 2022-01-13 22:46:10 +01:00
Karsten Hassel
c1be0180f9 change weather_spec 2022-01-13 22:33:57 +01:00
Karsten Hassel
2cfafe7bfe improve waitForElement 2022-01-13 21:52:47 +01:00
Karsten Hassel
42b80b18f8 testing wait alternatives 2022-01-13 00:50:15 +01:00
Christopher Fenner
9e4997aa81
Merge branch 'develop' into patch-1 2022-01-12 20:39:09 +01:00
Karsten Hassel
8cb6015930 refactor tests 2022-01-10 23:27:53 +01:00
Christopher Fenner
8417590893
update test case 2022-01-09 11:10:00 +01:00
Karsten Hassel
cd1fe4e182 weather test for new absolute property 2022-01-07 21:38:56 +01:00
CFenner
c56b601ab8
adjust test case 2022-01-06 21:49:21 +01:00
Karsten Hassel
5d8f2f5da1 iterate over timezones 2021-12-26 16:27:40 +01:00
Karsten Hassel
a954a62762 added test for calendar recurring event with checks the correct date displayed (related to #2752) 2021-12-26 14:30:38 +01:00
rejas
f54c06fb94 Add test for old items 2021-12-20 13:35:50 +01:00
Karsten Hassel
b1a46b365b increase load delay for modules tests 2021-10-22 22:49:10 +02:00
Karsten Hassel
1acbef5bfa increase testTimeout, minor changes tests e2e 2021-10-20 21:05:19 +02:00
Karsten Hassel
0fb9e0bc89 increase test delay for alert module test 2021-10-16 00:25:31 +02:00
Karsten Hassel
0ec80a7791 move weather-test to e2e 2021-10-16 00:05:12 +02:00
Karsten Hassel
1d12e57606 move calendar tests from category electron to e2e 2021-10-04 23:04:28 +02:00
Karsten Hassel
c67320f185 fix logger.js 2021-09-28 22:08:21 +02:00
Karsten Hassel
abcee8aa56 fix global-setup.js 2021-09-28 21:23:59 +02:00
Karsten Hassel
1034171e91 add CHANGELOG 2021-09-28 21:10:24 +02:00
Karsten Hassel
f750436b64 update module clock_es 2021-09-26 22:09:41 +02:00
Karsten Hassel
a4a8504558 update module clock 2021-09-26 22:02:29 +02:00
Karsten Hassel
385e5aabaa prettier 2021-09-26 00:29:03 +02:00
Karsten Hassel
d831315e20 update module newsfeed 2021-09-26 00:18:22 +02:00
Karsten Hassel
e0906f3462 update module helloworld 2021-09-25 23:52:38 +02:00
Karsten Hassel
6595b6a44f refactor global-setup.js 2021-09-25 23:45:34 +02:00
Karsten Hassel
0183d7a080 update modules alert and compliments 2021-09-25 23:37:37 +02:00
Karsten Hassel
89e803ee42 update without_modules.js and env_spec.js 2021-09-25 22:12:53 +02:00
Karsten Hassel
c0ce52abe3 change getDocument, delay needed, now 2 tests moved 2021-09-25 00:01:41 +02:00
Karsten Hassel
a1c7f20990 fix logger.js, move jsdom in startApplication 2021-09-24 21:30:51 +02:00
Karsten Hassel
0ef6f89d44 fix server.close() issue 2021-09-24 00:30:00 +02:00
Karsten Hassel
54b04962a8 snapshot 2021-09-23 22:52:32 +02:00
Karsten Hassel
60f8de282d snapshot 2021-09-23 00:05:30 +02:00
karsten13
b4350278a0 first tests 2021-09-21 23:48:29 +02:00