Chris Veilleux
86febca6a3
Fixed a bug passing None to an instance of Path
2021-03-10 15:35:38 -06:00
Chris Veilleux
5e90940896
new code to consolidate TTS cache handling into one module.
2021-03-10 13:38:17 -06:00
Kris Gesling
3679eb1355
Merge pull request #2838 from forslund/test/get_response-tests
...
get response tests
2021-03-10 23:44:48 +09:30
Åke Forslund
203e1fc740
Remove intent-service backwards compatibility
...
- Remove unused ContextManager import from mycroft.skills.intent_service
- Remove Old 'intent_failure' -> fallback handler
- Remove handling of fallback messages without the fallback_range
parameter
2021-03-07 12:59:59 +01:00
Chris Veilleux
6ed674bd3e
Merge remote-tracking branch 'origin/dev' into feature/mark-2
...
# Conflicts:
# mycroft/audio/__main__.py
# mycroft/client/speech/__main__.py
# mycroft/skills/__main__.py
# mycroft/util/process_utils.py
2021-02-26 11:49:30 -06:00
Kris Gesling
38839a1489
Merge pull request #1822 from forslund/feature/skill-api
...
Feature/skill api
2021-02-23 10:03:17 +09:30
Åke Forslund
d724720b21
Basic tests for get_response based skill methods
...
- get_response
- ask_yesno
- ask_selection
2021-02-14 17:18:20 +01:00
Åke Forslund
53b9e87b21
Move AnyCallable to common location
2021-02-14 14:20:58 +01:00
Kris Gesling
fa5576adf4
Merge pull request #2831 from MycroftAI/bugfix/google-voice
...
Upgrade gTTS to fix Google voice
2021-02-10 11:16:43 +09:30
Kris Gesling
c8494932ac
Remove deprecated Google TTS lang codes
2021-02-09 21:27:59 +09:30
Åke Forslund
9173e22460
Send correct conf to mimic when used as fallback
...
- Mimic is now sent the correct config when used as a fallback
- Tests updated to ensure this
2021-02-08 22:09:55 +01:00
Åke Forslund
56852594cc
Add test cases for the SkillApi
...
- Tests for the MycroftSkill side implementation
- Tests for the generated SkillApi objects
2021-02-08 07:37:50 +01:00
Kris Gesling
b1be522972
Merge pull request #2820 from MycroftAI/feature/gui-get
...
Feature/gui get
2021-02-05 14:41:03 +09:30
Kris Gesling
cae1cb751f
Extend GUI interface unittests
2021-02-04 16:12:22 +09:30
Kris Gesling
bfe2b59f90
Add get method for accessing GUI values
2021-02-04 16:12:22 +09:30
Chris Veilleux
5fe7949bfd
Added code to pass the packaging_type config to the pairing code endpoint. This was done to know if a device uses a Pantacor image. Selene will use this information to retrieve device information from Pantacor using their API.
2021-02-02 19:27:01 -06:00
Chris Veilleux
dcf54c0cc3
Refactored to abstract out duplicate code.
2021-02-02 19:22:20 -06:00
Åke Forslund
166e36fa84
Improve logic when waiting for play calls
...
Add logic to ensure the play_* functions are called at least once before
checking the call status.
2021-02-01 23:02:34 +01:00
Åke Forslund
3ede156c98
Only stop speaking if speaking is active
...
This also updates the relevant testcase
2021-02-01 20:26:44 +01:00
Åke Forslund
93747a13ed
Remove is_alive and all_loaded registration test
2021-01-28 17:24:21 +01:00
Åke Forslund
eeb44ede9a
Add test cases for ProcessStatus
2021-01-28 17:21:33 +01:00
Åke
99f43b964e
Merge pull request #2808 from MycroftAI/feature/vk-wait-for-service-msg
...
Add VK method to wait for audio service
2021-01-18 07:33:27 +01:00
Kris Gesling
89555380d8
Add VK method to wait for audio service
2021-01-18 11:16:41 +09:30
Åke Forslund
375adbbdf0
Make audioservice load backends without callback
2021-01-15 13:49:40 +01:00
Kris Gesling
5e9b1ac24b
Merge pull request #2801 from MycroftAI/bugfix/mimic2-cache-dir
...
Bugfix/mimic2 cache dir
2021-01-15 11:43:04 +09:30
Åke Forslund
83ed811dba
Add check to make sure speak message has metadata
...
This can occur if a custom made speak message is injected and VK should
handle malformed speak messages.
2021-01-10 21:03:25 +01:00
Åke Forslund
35fd035337
Add timeout waiting for config change
2021-01-10 21:02:54 +01:00
Kris Gesling
54eac52b11
merge dev into mark-2 branch
2021-01-06 22:17:25 +09:30
JarbasAI
f1d7141bf2
fix/intent_api ( #2786 )
...
* fix/fix/intent_api
* get active skills
* fix/intent_api
* fix/intent_api
* typos
Co-authored-by: jarbasal <jarbasai@mailfence.com>
2020-12-31 12:56:44 +09:30
Kris Gesling
fd5c8bb5e3
Merge branch 'dev' into feature/mark-2
2020-12-29 14:31:09 +09:30
Kris Gesling
b0884301a3
Merge pull request #2734 from MycroftAI/feat/skill_settings_sync
...
skill settings sync flag
2020-12-02 10:45:45 +09:30
Åke Forslund
843de8b64f
Base Mock config on the defualt config
...
This makes sure all config parameters are available.
2020-12-01 23:56:15 +11:00
Åke Forslund
21425da543
Add test for anonymous AdaptIntent
2020-11-24 11:02:52 +01:00
Kris Gesling
f2b7b0251b
Merge pull request #2757 from forslund/feature/ready-check
...
Feature: add Process Status and ensure all services ready
2020-11-12 09:16:43 +09:30
Kris Gesling
8b107ce733
Merge pull request #2742 from forslund/bugfix/vk-reset-config-spam
...
Fix Voight kampff reset of patched config
2020-11-06 14:38:28 +09:30
Åke Forslund
dfe909aa2e
Add a log for when config is patched
...
Since we have a reset log a matching info message for when updating the
config should be shown
2020-10-29 08:05:32 +01:00
Åke Forslund
3de34003cf
Use custom cleanup to reset patched config
...
original_config will now only live in the scenario part of the context
being automatically cleared at the end of each scenario. To reset the
patch a custom cleanup is added when the patch is performed.
2020-10-29 08:05:28 +01:00
Kris Gesling
e0c7016b4d
revert a temporary bugfix from PR #2626
2020-10-28 16:30:10 +09:30
Åke Forslund
0a9de0ab7c
Update to pyee 8.1.0
...
pyee 8.1.0 adds a small change to make the once call to be more safe in
multithreaded environments.
This switches back from the now deprecated BaseEventEmitter to the
standard EventEmitter.
2020-10-22 11:43:06 +02:00
Kris Gesling
8a1b989935
Merge pull request #2594 from forslund/feature/plugin-system
...
Plugin system for stt, tts, audioservices and wake word engines
2020-10-19 15:41:35 +09:30
Åke Forslund
7c4a3fa2f2
Remove is_alive and all_loaded registration test
2020-09-27 09:58:08 +02:00
Åke Forslund
48d1153c0c
Add test cases for ProcessStatus
2020-09-25 06:52:27 +02:00
Åke Forslund
bb4e705d64
Add unittests for the plugin util
2020-09-23 07:46:13 +02:00
Kris Gesling
ae72ebd247
Merge pull request #2599 from forslund/refactor/intent-service
...
Refactor intent service
2020-09-23 10:24:16 +09:30
katridi
6e197d0138
Bugfix/issue 2563 ( #2692 )
...
* Issue-2563 Added fallback to english model
* Added test case for checking config set up
* Added more descriptive log message
2020-09-22 15:01:01 +09:30
Åke Forslund
2debf2a7b7
Add basic test cases for gui interface
2020-09-18 07:26:21 +02:00
katridi
a185a9a4bf
Issue-2567 - Fixing not initialized dialog_render ( #2685 )
...
Fixes #2567
2020-09-15 22:10:39 +09:30
Åke Forslund
fc3d8ce801
Add MontonicEvent class
...
This handles jumps forward in time correctly
2020-09-10 13:26:25 +02:00
Kris Gesling
52b908f350
Merge pull request #2663 from forslund/feature/given-timeout
...
Voight Kampff given timeout
2020-09-09 14:32:25 +09:30
Kris Gesling
3eee84f053
Merge pull request #2679 from forslund/refactor/remove-imp
...
Refactor/remove imp
2020-08-24 01:28:34 +00:00
Åke Forslund
e2a7fe9b2a
Load test environment with importlib instead of imp
2020-08-21 08:00:57 +02:00
Kris Gesling
a3a869b883
Merge pull request #2672 from MycroftAI/remove/string-utils
...
Remove unnecessary string utils
2020-08-21 00:32:08 +00:00
Kris Gesling
cb2531c81c
Merge pull request #2671 from MycroftAI/remove/dialog-loader
...
remove deprecated DialogLoader class
2020-08-21 00:31:45 +00:00
Åke Forslund
8a8caa555d
Add test cases for the api methods
2020-08-20 14:38:58 +02:00
Kris Gesling
666178c483
remove unnecessary remove_last_slash method
2020-08-18 23:06:42 +09:30
Kris Gesling
ed46311cd8
remove unnecessary get_http method
2020-08-18 23:04:53 +09:30
Kris Gesling
2643caadf8
remove previously deprecated DialogLoader class
2020-08-18 22:56:34 +09:30
Kris Gesling
ac8e10898f
remove deprecated ThreadedEventEmitter
2020-08-18 16:00:51 +09:30
Kris Gesling
d70c425854
switch deprecated EventEmitter to other classes
2020-08-18 15:58:42 +09:30
Åke Forslund
9b4e47567e
Add context parameter to wait_for_dialog
...
This allows wait for dialog to respect the timeout set for the current
scenario.
2020-08-16 23:34:29 +02:00
Åke Forslund
03002bcf47
Add "given a timeout of X seconds"
...
The new given sets the timeout of the steps in a scenario. The timeout is reset after each scenario.
2020-08-16 23:16:51 +02:00
Åke Forslund
e93d23f0df
Split out adapt from the intent_service.
2020-08-13 08:12:53 +02:00
Åke Forslund
6edaa58558
set active lang to configured if missing from STT
...
If the STT doesn't send a lang code fallback to configured language
instead of hardcoded en-us
2020-08-10 07:41:44 +02:00
Kris Gesling
6f33cc0553
Merge pull request #2626 from MycroftAI/bugfix/random-vk-fail
...
sleep after skills loaded for any final setup
2020-07-17 23:03:02 +09:30
Kris Gesling
d4abc37861
sleep prior to tests to assist in bug diagnosis
2020-07-17 15:53:59 +09:30
Kris Gesling
77f1eaf3c8
Merge pull request #2541 from forslund/bugfix/jenkins-file-no-dockerfile-copy
...
CI: Use the docker -f flag instead of copying the Dockerfile
2020-07-07 16:15:21 +09:30
Åke Forslund
b7d709c3c8
Add wait_for_message() method to messagebus client
...
- Refactor message waiting into a MessageWaiter class to be able to use the
same code in both wait_for_message and wait_for_response.
- Add some basic unittests
2020-07-05 09:28:17 +02:00
Åke Forslund
ff1f07288e
Rename Dockerfile.test to Dockerfile
2020-07-01 07:22:50 +02:00
Kris Gesling
247c6d30a3
add test - specific skill should not reply
2020-06-18 22:33:22 +09:30
Åke
a0c7ea7caf
Merge pull request #2560 from forslund/refactor/settings-cleanup
...
Refactor settings cleanup
2020-05-31 13:37:34 +02:00
Åke
16145909a8
Merge pull request #2589 from forslund/refactor/speech-client
...
Refactor wake-word waiting and record phrase
2020-05-31 13:37:02 +02:00
Åke Forslund
e0e5f7fb2f
Add test for cancelling the download timer
2020-05-27 22:08:14 +02:00
Åke Forslund
86a978fadf
Fix audio service startup without Internet
...
If started up without Network connection the audio service would crash
importing the google_tts module as it tried to fetch language list from
google.
This restructures it to be a just-in-time check. It also adds a cached
list of supported languages to use if an error occurs fetching language
codes.
A small fix allowing "en-US" to be matched to "en-us" instead of the
generic "en" is also included.
2020-05-27 21:28:26 +02:00
Åke Forslund
926d3ff1c1
Extract noise-tracking from _record_phrase
...
_record_phrase now uses a helper class to track the noise in a sentence
to determine when the user has stopped speaking.
The logic should be the same but the same but allow for easier testing
and manipulation.
2020-05-26 12:12:12 +02:00
Åke Forslund
55bdb9db74
Reactivate dynamic energy calculation test
2020-05-26 12:12:12 +02:00
Åke Forslund
567e08809a
Refactor _wait_for_wakeword
...
- Add RollingMean data structure
- Add simple CyclicBuffer data structure
- Move out post find actions into separate method
2020-05-26 12:12:12 +02:00
Åke Forslund
010562f3e1
Fix remove_fallback()
...
remove_fallback() was mainly created for use internally during shutdown
and required the wrapped callable to be able to remove a handler. This
makes it general, using a mapping to find the wrapper from a handler if
needed. The method now also returns the success/failure status
2020-05-19 10:51:53 +02:00
Åke Forslund
73fd98aee1
Add test cases for adding / removing fallbacks
2020-05-19 10:51:47 +02:00
Åke Forslund
e08f630bea
Minor header fixes in voight_kampff
...
- Copyright year
- typo
2020-05-18 14:48:19 +02:00
Åke Forslund
46c8a6b51f
Add Voight Kampff support setting configurations
...
Adds the "Given the user's {config} is {value}" step implementation
This will patch the configuration with a section from a dictionary that
can either be a global (shipped in
mycroft/res/{lang}/configurations.json) or shipped with the test
definition. The file should be named the same as the feature file but
instead of ".feature" the extension should be ".config.json".
mycroft/res/text/en-us/configurations.json contains a couple of
pre-defined configurations that can be applied
- units (metric/imperial)
- location (Stockholm)
After each scenario any applied patch will be cleared
2020-05-18 14:48:14 +02:00
Åke
90d2570cc3
Merge pull request #2575 from PureTryOut/optional-deps
...
Move requirements.txt to a new requirements folder and add optional deps
2020-05-14 15:04:56 +02:00
Åke Forslund
094c2c28d0
Test loading of phonetic spelling dictionary
...
This also normalizes the path slightly to make sure that the phonetic
spelling is loaded even if the lang code contains capitals.
2020-05-12 08:58:18 +02:00
Åke Forslund
8c0aca6d4c
Fix typo in mimic test case
...
An underscore instead of a . made the subprocess check output always
pass.
2020-05-11 21:43:28 +02:00
Åke Forslund
4d065ff7fe
Add basic unittest for espeak
2020-05-11 16:14:24 +02:00
Bart Ribbers
531f78c499
Move requirements.txt to a new requirements folder and add optional deps
...
Some dependencies aren't actually required but can be optionally
installed for extra functionality.
The Chromecast is an optional audio backend
VLC is an optional audio backend
pyalsaaudio is only used by the mark1 enclosure
google-api-python-client is an optional STT backend, by default Mycroft
uses the Mycroft servers
2020-05-11 15:31:10 +02:00
Åke Forslund
5caf415a15
Add tests for context decorators
2020-05-11 06:50:36 +02:00
Bart Ribbers
4d01269f35
Explicitely run the messagebus test with Python3
...
/usr/bin/python might not always point to Python 3, and it might not
even exist, depending on the distribution. To make sure we always run
with Python 3, explicitely call /usr/bin/python3
Also update the service start command and remove the outdated message
method tests
2020-05-06 14:28:27 +02:00
Kris Gesling
6640861b30
Merge pull request #2548 from codyreinold/bugfix/issue-2516
...
Issues-2516 - Resolved IBM Cloud integration issue
2020-04-27 12:21:27 +00:00
Åke
bcb426ab69
Merge pull request #2496 from forslund/test/util
...
Refactor and test util functions
2020-04-27 10:47:59 +02:00
Cody Reinold
d6c9a64c80
Issue-2516 - Use requests.post kwarg to pass URL params
2020-04-27 03:23:07 -04:00
Åke Forslund
1258480f30
Improve audio utils log
2020-04-27 08:38:44 +02:00
Cody Reinold
e50ea28dd5
Issues-2516 - Resolved IBM Cloud integration issue, switching from user / pass to api key.
2020-04-26 01:43:39 -04:00
Åke Forslund
d1b6db306f
Add test case for sending items added before start
2020-04-20 10:48:24 +02:00
Åke Forslund
c5dccc16e2
Improve getting tmp download path
2020-04-17 23:42:04 +02:00
Åke Forslund
a3c625bb0a
Add basic test for download utility
2020-04-17 23:42:04 +02:00
Åke Forslund
06157e3331
Reuse ensure_directory_exists() in create_file()
...
ensure_directory_exists() now takes the directory permissions as an
optional argument.
2020-04-17 23:42:04 +02:00
Åke Forslund
05695f5b5f
Add simple test for get_platform
2020-04-17 23:42:04 +02:00
Åke Forslund
aa42552d97
Refactor test change loglevel and add tests for process_utils
2020-04-17 23:42:04 +02:00
Åke Forslund
e218533cf6
Split tests into several files
2020-04-17 23:42:04 +02:00
Åke Forslund
e651e39588
Add test for record function
2020-04-17 23:42:04 +02:00
Åke Forslund
60c0af69d6
Replace read_stripped_lines with generator
2020-04-17 23:42:04 +02:00
Åke Forslund
0d79af8ce2
Add tests for reading file functions
2020-04-17 23:42:04 +02:00
Åke Forslund
76ff53a615
Add tests for string related utils
2020-04-17 23:42:04 +02:00
Åke Forslund
2582d78237
Add tests for audio playback functions
2020-04-17 23:42:04 +02:00
Åke Forslund
f872daf7ca
Add tests for cache and file functions.
2020-04-17 23:42:04 +02:00
Åke Forslund
c52f2837f1
Add test for time utils
2020-04-17 23:42:04 +02:00
Åke Forslund
b3ce33ab70
Update test to match change
...
Also minor cleaning up of test code
2020-04-02 19:29:31 +02:00
Åke
28c3a61e1c
Merge pull request #2503 from forslund/bugfix/converse-error
...
Bugfix Converse error
2020-04-02 07:45:00 +02:00
Kris Gesling
1a96f04020
Add single Voight Kampff module interface
...
Takes in arguments for both test_setup.py and behave test runner. Parses
any args for test_setup and passes any remaining arguments to behave.
This moves argparsing out of the test_setup main() allowing the helper commands
to pass in pre-parsed arguments rather than adding logic inside main to
differentiate between a list and a preparsed arument object
2020-03-25 07:40:01 +01:00
Åke Forslund
9fe158d841
Prepare for multi-lang support
2020-03-24 10:42:07 +01:00
Åke Forslund
00c83c5139
Add repo and branch selection for test_setup.py
...
--url can be added to specify the repo url
--branch can be added to specify a specific branch
2020-03-24 10:42:07 +01:00
Åke Forslund
c33f9ee875
Restructure test_setup.py according to review
2020-03-24 10:42:07 +01:00
Åke Forslund
f8c6107ea5
Update readme with some new steps
2020-03-24 10:42:07 +01:00
Åke Forslund
8e7e19ecc2
Add help text to test_setup.py parameters
2020-03-24 10:42:07 +01:00
Åke Forslund
daeac964e0
Rename tested-skills argument to test-skills
2020-03-24 10:42:07 +01:00
Åke Forslund
5d6cb83899
Make all fields in config optional
2020-03-24 10:42:07 +01:00
Åke Forslund
e0dec90d17
Allow test_setup to update skills
2020-03-24 10:42:07 +01:00
Åke Forslund
2a7b0ccef9
Update voight kampff Readme with some extra info
2020-03-24 10:42:07 +01:00
Chris Veilleux
1a643b0d4d
re-order build steps for performance. least likely to change first.
2020-03-24 10:42:07 +01:00
Åke Forslund
a6d1e91942
Add auto-retry
...
This switches behave to the current dev release including the autoretry
system.
2020-03-24 10:42:07 +01:00
Åke Forslund
0ad91ce321
Add an event that can be waited on instead of sleep
2020-03-24 10:42:07 +01:00
Åke Forslund
223274d2ad
Update environment variables for job
...
Set USER and CI
2020-03-24 10:42:07 +01:00
Åke Forslund
d86e8257a4
Add a basic mycroft.conf
2020-03-24 10:42:07 +01:00
Åke Forslund
0f860162e3
Update run_test_suite.sh
...
- Pulseaudio is launched if on CI
- remove hard-coding of start-mycroft.sh
2020-03-24 10:42:02 +01:00
Åke Forslund
353239cbc2
Move more common functions to voight kampff tools
2020-03-23 11:41:13 +01:00
Åke Forslund
0d5520be4a
Reduce sleep time while waiting for response
2020-03-23 11:41:13 +01:00
Åke Forslund
2055b50238
Add before_feature logging current test
2020-03-23 11:41:13 +01:00
Åke Forslund
fa88562a8c
Fix timeout of wait for message
...
The counter didn't increment as intended
2020-03-23 11:41:13 +01:00
Åke Forslund
9a5f1f6f7e
Add shared tools
2020-03-23 11:41:13 +01:00
Åke Forslund
0ea1af126d
Reduce safety timeouts
2020-03-23 11:41:13 +01:00
Åke Forslund
d451e1c1e0
Add more info on captured response (skill and dialog)
2020-03-23 11:41:13 +01:00
Åke Forslund
b79fe04eb8
Extend timeout after scenario
2020-03-23 11:41:13 +01:00
Åke Forslund
51f07a5d96
Add assert message if no dialog is recorded
2020-03-23 11:41:13 +01:00
Åke Forslund
c159377acb
Consume matched messages.
2020-03-23 11:41:13 +01:00
Åke Forslund
b43785a403
Recreate messed up assert messages
2020-03-23 11:41:13 +01:00
Åke Forslund
1470151c2b
Add alternatives for user replies
2020-03-23 11:41:13 +01:00
Åke Forslund
0c873b5065
Update skill list for default skills test
2020-03-23 11:41:13 +01:00
Åke Forslund
75f92a66dd
Add handler to capture messages of specific type
2020-03-23 11:41:13 +01:00
Åke Forslund
12f2e63cc3
Share only identity and allure in separate volume
...
- Sharing only the identity file removes the need for clearing the skill
sandbox dir and padatious cache
- Make things a bit cleaner with separate Allure volume
2020-03-23 11:41:13 +01:00
Åke Forslund
2592c9b1c2
Add clearer feedback on failures
...
Will now print all responses received from Mycroft
2020-03-23 11:41:13 +01:00
Åke Forslund
15148fadf5
Rework bus hooks
...
Override the bus clients on_message method and collect all messages in a
list. This will make it harder to miss a message during a test
2020-03-23 11:41:13 +01:00
Åke Forslund
38d43f2bb7
Move Jenkins specific commands into Jenkinsfile
...
Allure commandline and chown command are now run through the Jenkinsfile
instead of through the run_test_suite.sh
2020-03-23 11:41:13 +01:00
Åke Forslund
d0a6ff4a80
Add mycroft-core to python-path
2020-03-23 11:41:13 +01:00
Chris Veilleux
00acf2b10c
Update docker build
...
Docker build will now perform most actions of the dev-setup making it
possible to use caches in a greater extent speeding up the build
2020-03-23 11:41:13 +01:00
Chris Veilleux
b436e5575a
Add allure test reports
...
Behave will generate test results in the allure format, this will be
picked up by Jenkins and sent of to a standalone webserver.
2020-03-23 11:41:13 +01:00
Åke Forslund
fc9c462a37
Add possibility to send a user response as Then step
2020-03-23 11:41:13 +01:00
Åke Forslund
4a1dbd7e04
Add dockerfile for running voight_kampff test
2020-03-23 11:41:13 +01:00
Åke Forslund
b4507b7866
Add Voight Kampff test
...
The Voight kampff test is an integration test collecting and running
behave test of skills.
2020-03-23 11:41:09 +01:00
Åke Forslund
6dce1096e3
Test that all skill_id's are processed
...
Including a case where an error occur.
2020-03-15 22:23:16 +01:00
Åke Forslund
58f0ac8b9e
Simplify the converse callings
...
Remove the use of the separate error message and use the wait_for_reply method
to get the converse result. The error message is left to guarantee
compatibility.
2020-03-07 11:11:21 +01:00