diff --git a/testData/deviceReporter/acceptanceTests/magic.JSON b/testData/deviceReporter/acceptanceTests/magic.JSON new file mode 100644 index 000000000..d68c01192 --- /dev/null +++ b/testData/deviceReporter/acceptanceTests/magic.JSON @@ -0,0 +1,3 @@ +[ + { "id": "com.freedomscientific.magic" } +] diff --git a/testData/preferences/acceptanceTests/magic_application.json b/testData/preferences/acceptanceTests/magic_application.json new file mode 100644 index 000000000..21ebe34ee --- /dev/null +++ b/testData/preferences/acceptanceTests/magic_application.json @@ -0,0 +1,61 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/applications/com.freedomscientific.magic": { + "Options.PrimarySynthesizer" : "eloq", + "options.SayAllIndicateCaps" : false, + "options.TypingEcho": 3, + "options.SayAllMode": 0, + "options.SayAllIgnoreShiftKeys": true, + "ENU-Global.Rate" : 100, + "ENU-Global.Pitch" : 75, + "ENU-Global.Volume" : 100, + "ENU-Global.Punctuation" : 2, + "ENU-Global.Rate": 100, + "ENU-JAWSCursor.Rate": 100, + "ENU-Keyboard.Rate": 100, + "ENU-MenuAndDialog.Rate": 100, + "ENU-Message.Rate": 100, + "ENU-PCCursor.Rate": 100, + "ENU-Global.Pitch": 75, + "ENU-JAWSCursor.Pitch": 75, + "ENU-Keyboard.Pitch": 75, + "ENU-MenuAndDialog.Pitch": 75, + "ENU-Message.Pitch": 75, + "ENU-PCCursor.Pitch": 75, + "ENU-Global.Volume": 100, + "ENU-JAWSCursor.Volume": 100, + "ENU-Keyboard.Volume": 100, + "ENU-MenuAndDialog.Volume": 100, + "ENU-Message.Volume": 100, + "ENU-PCCursor.Volume": 100, + "ENU-Global.Punctuation": 2, + "ENU-JAWSCursor.Punctuation": 2, + "ENU-Keyboard.Punctuation": 2, + "ENU-MenuAndDialog.Punctuation": 2, + "ENU-Message.Punctuation": 2, + "ENU-PCCursor.Punctuation": 2, + "ENU-Global.SynthLangString": "Italian", + "ENU-JAWSCursor.SynthLangString": "Italian", + "ENU-Keyboard.SynthLangString": "Italian", + "ENU-MenuAndDialog.SynthLangString": "Italian", + "ENU-Message.SynthLangString": "Italian", + "ENU-PCCursor.SynthLangString": "Italian", + "mag.Size": 1.5, + "mag.TextViewerFontSize": 14, + "mag.TextViewerFontFaceName": "Arial", + "mag.startmagnified": 1, + "mag.ActiveTracking": 1, + "mag.MouseDoubleSize": 1, + "mag.UnmagnifiedMouseDoubleSize": 1, + "mag.MouseCrossHair": 1, + "mag.UnmagnifiedMouseCrossHair": 1 + } + } + } + } + } +} diff --git a/testData/preferences/acceptanceTests/magic_common.JSON b/testData/preferences/acceptanceTests/magic_common.JSON new file mode 100644 index 000000000..46d903d97 --- /dev/null +++ b/testData/preferences/acceptanceTests/magic_common.JSON @@ -0,0 +1,29 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/common/auditoryOutLanguage": "fr", + "http://registry.gpii.net/common/speechSynthesizer": "eloq", + "http://registry.gpii.net/common/speechRate": 40, + "http://registry.gpii.net/common/pitch": 0.75, + "http://registry.gpii.net/common/volume": 0.5, + "http://registry.gpii.net/common/punctuationVerbosity": "most", + "http://registry.gpii.net/common/announceCapitals": false, + "http://registry.gpii.net/common/readingUnit": "sentence", + "http://registry.gpii.net/common/stickyKeys": false, + "http://registry.gpii.net/common/wordEcho": true, + "http://registry.gpii.net/common/keyEcho": true, + "http://registry.gpii.net/common/magnifierEnabled": true, + "http://registry.gpii.net/common/magnification": 1.5, + "http://registry.gpii.net/common/fontSize": 40, + "http://registry.gpii.net/common/fontFaceFontName": "Arial", + "http://registry.gpii.net/common/tracking": "mouse", + "http://registry.gpii.net/common/cursorSize": 1, + "http://registry.gpii.net/common/showCrosshairs": true + } + } + } + } +} \ No newline at end of file diff --git a/testData/preferences/acceptanceTests/magic_common2.JSON b/testData/preferences/acceptanceTests/magic_common2.JSON new file mode 100644 index 000000000..094d999e7 --- /dev/null +++ b/testData/preferences/acceptanceTests/magic_common2.JSON @@ -0,0 +1,29 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/common/auditoryOutLanguage": "it", + "http://registry.gpii.net/common/speechSynthesizer": "eloq", + "http://registry.gpii.net/common/speechRate": 40, + "http://registry.gpii.net/common/pitch": 0.1, + "http://registry.gpii.net/common/volume": 0.1, + "http://registry.gpii.net/common/punctuationVerbosity": "none", + "http://registry.gpii.net/common/announceCapitals": false, + "http://registry.gpii.net/common/readingUnit": "line", + "http://registry.gpii.net/common/stickyKeys": false, + "http://registry.gpii.net/common/wordEcho": false, + "http://registry.gpii.net/common/keyEcho": false, + "http://registry.gpii.net/common/magnifierEnabled": true, + "http://registry.gpii.net/common/magnification": 2, + "http://registry.gpii.net/common/fontSize": 30, + "http://registry.gpii.net/common/fontFaceFontName": "Arial", + "http://registry.gpii.net/common/tracking": "caret", + "http://registry.gpii.net/common/cursorSize": 1, + "http://registry.gpii.net/common/showCrosshairs": true + } + } + } + } +} \ No newline at end of file diff --git a/testData/preferences/acceptanceTests/magic_common3.JSON b/testData/preferences/acceptanceTests/magic_common3.JSON new file mode 100644 index 000000000..4576c272c --- /dev/null +++ b/testData/preferences/acceptanceTests/magic_common3.JSON @@ -0,0 +1,28 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/common/auditoryOutLanguage": "fr-CA", + "http://registry.gpii.net/common/speechSynthesizer": "eloq", + "http://registry.gpii.net/common/speechRate": 100, + "http://registry.gpii.net/common/pitch": 1, + "http://registry.gpii.net/common/volume": 1, + "http://registry.gpii.net/common/punctuationVerbosity": "most", + "http://registry.gpii.net/common/announceCapitals": true, + "http://registry.gpii.net/common/readingUnit": "paragraph", + "http://registry.gpii.net/common/stickyKeys": true, + "http://registry.gpii.net/common/wordEcho": false, + "http://registry.gpii.net/common/keyEcho": true, + "http://registry.gpii.net/common/magnifierEnabled": false, + "http://registry.gpii.net/common/magnification": 1, + "http://registry.gpii.net/common/fontSize": 22, + "http://registry.gpii.net/common/fontFaceFontName": "Arial", + "http://registry.gpii.net/common/cursorSize": 0, + "http://registry.gpii.net/common/showCrosshairs": false + } + } + } + } +} \ No newline at end of file diff --git a/testData/solutions/win32.json5 b/testData/solutions/win32.json5 index fdd9a3415..ba32e59a5 100644 --- a/testData/solutions/win32.json5 +++ b/testData/solutions/win32.json5 @@ -1,4 +1,764 @@ { + "com.freedomscientific.magic": { + "name": "MAGIC", + "contexts": { + "OS": [ + { + "id": "win32" + } + ] + }, + "settingsHandlers": { + "configuration1": { + "type": "gpii.settingsHandlers.INISettingsHandler", + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.JCF" + }, + "supportedSettings": { + "Voice Profiles.ActiveVoiceProfileName": {}, + "options.SayAllIndicateCaps": {}, + "options.TypingEcho": {}, + "options.SayAllMode": {}, + "options.SayAllIgnoreShiftKeys": {} + }, + "capabilities": [ + "http://registry\\.gpii\\.net/common/screenReaderTTSEnabled" + ], + "capabilitiesTransformations": { + "Voice Profiles\\.ActiveVoiceProfileName": { + "literalValue": "GPII" + }, + "options\\.SayAllIndicateCaps": "http://registry\\.gpii\\.net/common/announceCapitals", + "options\\.TypingEcho": { // (1=keyEcho, 2=wordEcho, 3=key&wordEcho) + "transform": { + "type": "fluid.transforms.condition", + "condition": { + "transform": { + "type": "fluid.transforms.binaryOp", + "leftPath": "http://registry\\.gpii\\.net/common/keyEcho", + "rightPath": "http://registry\\.gpii\\.net/common/wordEcho", + "operator": "&&" + } + }, + "true": 3, + "false": { + "transform": { + "type": "fluid.transforms.condition", + "conditionPath": "http://registry\\.gpii\\.net/common/keyEcho", + "true": 1, + "false": { + "transform": { + "type": "fluid.transforms.condition", + "conditionPath": "http://registry\\.gpii\\.net/common/wordEcho", + "true": 2 + } + } + } + } + } + }, + "options\\.SayAllMode": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/readingUnit", + "match": { + "line": 0, + "sentence": 1, + "paragraph": 2 + } + } + }, + "options\\.SayAllIgnoreShiftKeys": "http://registry\\.gpii\\.net/common/stickyKeys" + }, + "inverseCapabilitiesTransformations": { + "http://registry\\.gpii\\.net/common/announceCapitals": "options\\.SayAllIndicateCaps", + "http://registry\\.gpii\\.net/common/keyEcho": { + "transform": { + "type": "valueMapper", + "defaultInputPath": "options\\.TypingEcho", // (1=keyEcho, 2=wordEcho, 3=key&wordEcho) + "match": [{ + inputValue: 1, + outputValue: true + }, { + inputValue: 3, + outputValue: true + }], + "noMatch": { + "outputValue": false + } + } + }, + "http://registry\\.gpii\\.net/common/wordEcho": { + "transform": { + "type": "valueMapper", + "defaultInputPath": "options\\.TypingEcho", // (1=keyEcho, 2=wordEcho, 3=key&wordEcho) + "match": [{ + inputValue: 2, + outputValue: true + }, { + inputValue: 3, + outputValue: true + }], + "noMatch": { + "outputValue": false + } + } + }, + "http://registry\\.gpii\\.net/common/readingUnit": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "options\\.SayAllMode", + "match": [{ + inputValue: 0, + outputValue: "line" + }, { + inputValue: 1, + outputValue: "sentence" + }, { + inputValue: 2, + outputValue: "paragraph" + }] + } + } + } + }, + "configuration2": { + "type": "gpii.settingsHandlers.INISettingsHandler", + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\VoiceProfiles\\GPII.VPF" + }, + "supportedSettings": { + "Options.PrimarySynthesizer": {}, + "ENU-Global.Rate": {}, + "ENU-JAWSCursor.Rate": {}, + "ENU-Keyboard.Rate": {}, + "ENU-MenuAndDialog.Rate": {}, + "ENU-Message.Rate": {}, + "ENU-PCCursor.Rate": {}, + "ENU-Global.Pitch": {}, + "ENU-JAWSCursor.Pitch": {}, + "ENU-Keyboard.Pitch": {}, + "ENU-MenuAndDialog.Pitch": {}, + "ENU-Message.Pitch": {}, + "ENU-PCCursor.Pitch": {}, + "ENU-Global.Volume": {}, + "ENU-JAWSCursor.Volume": {}, + "ENU-Keyboard.Volume": {}, + "ENU-MenuAndDialog.Volume": {}, + "ENU-Message.Volume": {}, + "ENU-PCCursor.Volume": {}, + "ENU-Global.Punctuation": {}, + "ENU-JAWSCursor.Punctuation": {}, + "ENU-Keyboard.Punctuation": {}, + "ENU-MenuAndDialog.Punctuation": {}, + "ENU-Message.Punctuation": {}, + "ENU-PCCursor.Punctuation": {}, + "ENU-Global.SynthLangString": {}, + "ENU-JAWSCursor.SynthLangString": {}, + "ENU-Keyboard.SynthLangString": {}, + "ENU-MenuAndDialog.SynthLangString": {}, + "ENU-Message.SynthLangString": {}, + "ENU-PCCursor.SynthLangString": {} + }, + "capabilities": [], + "capabilitiesTransformations": { + "Options\\.PrimarySynthesizer": "http://registry\\.gpii\\.net/common/speechSynthesizer", + "ENU-Global\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ENU-JAWSCursor\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ENU-Keyboard\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ENU-MenuAndDialog\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ENU-Message\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ENU-PCCursor\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ENU-Global\\.Pitch": { + "transform": { + "type": "fluid.transforms.round", + "input": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/pitch", + "factor": 99, + "offset": 1 + } + } + } + }, + "ENU-JAWSCursor\\.Pitch": { + "transform": { + "type": "fluid.transforms.round", + "input": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/pitch", + "factor": 99, + "offset": 1 + } + } + } + }, + "ENU-Keyboard\\.Pitch": { + "transform": { + "type": "fluid.transforms.round", + "input": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/pitch", + "factor": 99, + "offset": 1 + } + } + } + }, + "ENU-MenuAndDialog\\.Pitch": { + "transform": { + "type": "fluid.transforms.round", + "input": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/pitch", + "factor": 99, + "offset": 1 + } + } + } + }, + "ENU-Message\\.Pitch": { + "transform": { + "type": "fluid.transforms.round", + "input": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/pitch", + "factor": 99, + "offset": 1 + } + } + } + }, + "ENU-PCCursor\\.Pitch": { + "transform": { + "type": "fluid.transforms.round", + "input": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/pitch", + "factor": 99, + "offset": 1 + } + } + } + }, + "ENU-Global\\.Volume": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/volume", + "factor": 100 + } + }, + "ENU-JAWSCursor\\.Volume": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/volume", + "factor": 100 + } + }, + "ENU-Keyboard\\.Volume": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/volume", + "factor": 100 + } + }, + "ENU-MenuAndDialog\\.Volume": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/volume", + "factor": 100 + } + }, + "ENU-Message\\.Volume": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/volume", + "factor": 100 + } + }, + "ENU-PCCursor\\.Volume": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "http://registry\\.gpii\\.net/common/volume", + "factor": 100 + } + }, + "ENU-Global\\.Punctuation": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", + "match": { + "none": 0, + "some": 1, + "most": 2, + "all": 3 + } + } + }, + "ENU-JAWSCursor\\.Punctuation": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", + "match": { + "none": 0, + "some": 1, + "most": 2, + "all": 3 + } + } + }, + "ENU-Keyboard\\.Punctuation": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", + "match": { + "none": 0, + "some": 1, + "most": 2, + "all": 3 + } + } + }, + "ENU-MenuAndDialog\\.Punctuation": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", + "match": { + "none": 0, + "some": 1, + "most": 2, + "all": 3 + } + } + }, + "ENU-Message\\.Punctuation": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", + "match": { + "none": 0, + "some": 1, + "most": 2, + "all": 3 + } + } + }, + "ENU-PCCursor\\.Punctuation": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", + "match": { + "none": 0, + "some": 1, + "most": 2, + "all": 3 + } + } + }, + "ENU-Global\\.SynthLangString": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/auditoryOutLanguage", + "match": { + "en-US": "American English", + "en-GB": "British English", + "fr": "French", + "fr-CA": "French Canadian", + "it": "Italian", + "pt-BR": "Brazilian Portuguese", + "de": "German", + "es-US": "Latin American Spanish", + "es-ES": "Castilian Spanish", + "fi": "Finnish" + } + } + }, + "ENU-JAWSCursor\\.SynthLangString": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/auditoryOutLanguage", + "match": { + "en-US": "American English", + "en-GB": "British English", + "fr": "French", + "fr-CA": "French Canadian", + "it": "Italian", + "pt-BR": "Brazilian Portuguese", + "de": "German", + "es-US": "Latin American Spanish", + "es-ES": "Castilian Spanish", + "fi": "Finnish" + } + } + }, + "ENU-Keyboard\\.SynthLangString": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/auditoryOutLanguage", + "match": { + "en-US": "American English", + "en-GB": "British English", + "fr": "French", + "fr-CA": "French Canadian", + "it": "Italian", + "pt-BR": "Brazilian Portuguese", + "de": "German", + "es-US": "Latin American Spanish", + "es-ES": "Castilian Spanish", + "fi": "Finnish" + } + } + }, + "ENU-MenuAndDialog\\.SynthLangString": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/auditoryOutLanguage", + "match": { + "en-US": "American English", + "en-GB": "British English", + "fr": "French", + "fr-CA": "French Canadian", + "it": "Italian", + "pt-BR": "Brazilian Portuguese", + "de": "German", + "es-US": "Latin American Spanish", + "es-ES": "Castilian Spanish", + "fi": "Finnish" + } + } + }, + "ENU-Message\\.SynthLangString": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/auditoryOutLanguage", + "match": { + "en-US": "American English", + "en-GB": "British English", + "fr": "French", + "fr-CA": "French Canadian", + "it": "Italian", + "pt-BR": "Brazilian Portuguese", + "de": "German", + "es-US": "Latin American Spanish", + "es-ES": "Castilian Spanish", + "fi": "Finnish" + } + } + }, + "ENU-PCCursor\\.SynthLangString": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/auditoryOutLanguage", + "match": { + "en-US": "American English", + "en-GB": "British English", + "fr": "French", + "fr-CA": "French Canadian", + "it": "Italian", + "pt-BR": "Brazilian Portuguese", + "de": "German", + "es-US": "Latin American Spanish", + "es-ES": "Castilian Spanish", + "fi": "Finnish" + } + } + } + }, + "inverseCapabilitiesTransformations": { + "http://registry\\.gpii\\.net/common/speechSynthesizer": "Options\\.PrimarySynthesizer", + "http://registry\\.gpii\\.net/common/speechRate": "ENU-Global\\.Rate", + "http://registry\\.gpii\\.net/common/speechRate": "ENU-JAWSCursor\\.Rate", + "http://registry\\.gpii\\.net/common/speechRate": "ENU-Keyboard\\.Rate", + "http://registry\\.gpii\\.net/common/speechRate": "ENU-MenuAndDialog\\.Rate", + "http://registry\\.gpii\\.net/common/speechRate": "ENU-Message\\.Rate", + "http://registry\\.gpii\\.net/common/speechRate": "ENU-PCCursor\\.Rate", + "http://registry\\.gpii\\.net/common/pitch": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "ENU-Global\\.Pitch", + "factor": 0.010101, + "offset": -0.010101 + } + }, + "http://registry\\.gpii\\.net/common/volume": { + "transform": { + "type": "fluid.transforms.linearScale", + "inputPath": "ENU-Global\\.Volume", + "factor": 0.01 + } + }, + "http://registry\\.gpii\\.net/common/punctuationVerbosity": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "ENU-Global\\.Punctuation", + "match": [{ + inputValue: 0, + outputValue: "none" + }, { + inputValue: 1, + outputValue: "some" + }, { + inputValue: 2, + outputValue: "most" + }, { + inputValue: 3, + outputValue: "all" + }] + }, + + }, + "http://registry\\.gpii\\.net/common/auditoryOutLanguage": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "ENU-Global\\.SynthLangString", + "match": { + "American English": "en-US", + "British English": "en-GB", + "French": "fr", + "French Canadian": "fr-CA", + "Italian": "it", + "Brazilian Portuguese": "pt-BR", + "German": "de", + "Latin American Spanish": "es-US", + "Castilian Spanish": "es-ES", + "Finnish": "fi" + } + } + } + } + }, + "configuration3": { + "type": "gpii.settingsHandlers.INISettingsHandler", + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.MCF" + }, + "supportedSettings": { + "mag.Size": {}, + "mag.TextViewerFontSize": {}, + "mag.TextViewerFontFaceName": {}, + "mag.startmagnified": {}, + "mag.ActiveTracking": {}, + "mag.MouseDoubleSize": {}, + "mag.UnmagnifiedMouseDoubleSize": {}, + "mag.MouseCrossHair": {}, + "mag.UnmagnifiedMouseCrossHair": {} + }, + "capabilities": [], + "capabilitiesTransformations": { + "mag\\.Size": "http://registry\\.gpii\\.net/common/magnification", + "mag\\.TextViewerFontSize": "http://registry\\.gpii\\.net/common/fontSize", + "mag\\.TextViewerFontFaceName": "http://registry\\.gpii\\.net/common/fontFaceFontName", + "mag\\.startmagnified": { + "transform": { + "type": "fluid.transforms.condition", + "conditionPath": "http://registry\\.gpii\\.net/common/magnifierEnabled", + "true": 1, + "false": 0 + } + }, + "mag\\.ActiveTracking": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "http://registry\\.gpii\\.net/common/tracking", + "match": { + "mouse": 1, + "caret": 1, + "focus": 1 + } + } + }, + "mag\\.MouseDoubleSize": { + "transform": { + "type": "fluid.transforms.condition", + "condition": { + "transform":{ + "type": "fluid.transforms.binaryOp", + "leftPath": "http://registry\\.gpii\\.net/common/cursorSize", + "right": 1, + "operator": "===" + } + }, + "true": 1, + "false": 0 + } + }, + "mag\\.UnmagnifiedMouseDoubleSize": { + "transform": { + "type": "fluid.transforms.condition", + "condition": { + "transform":{ + "type": "fluid.transforms.binaryOp", + "leftPath": "http://registry\\.gpii\\.net/common/cursorSize", + "right": 1, + "operator": "===" + } + }, + "true": 1, + "false": 0 + } + }, + "mag\\.MouseCrossHair": { + "transform": { + "type": "fluid.transforms.condition", + "conditionPath": "http://registry\\.gpii\\.net/common/showCrosshairs", + "true": 1, + "false": 0 + } + }, + "mag\\.UnmagnifiedMouseCrossHair": { + "transform": { + "type": "fluid.transforms.condition", + "conditionPath": "http://registry\\.gpii\\.net/common/showCrosshairs", + "true": 1, + "false": 0 + } + } + }, + "inverseCapabilitiesTransformations": { + "http://registry\\.gpii\\.net/common/magnification": "mag\\.Size", + "http://registry\\.gpii\\.net/common/fontSize": "mag\\.TextViewerFontSize", + "http://registry\\.gpii\\.net/common/fontFaceFontName": "mag\\.TextViwerFontFaceName", + "http://registry\\.gpii\\.net/common/magnifierEnabled": { + "transform": { + "type": "valueMapper", + "defaultInputPath": "mag\\.startmagnified", + "match": [{ + inputValue: 1, + outputValue: true + }, { + inputValue: 0, + outputValue: false + }] + } + }, + "http://registry\\.gpii\\.net/common/tracking": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "mag\\.ActiveTracking", + "match": [{ + inputValue: 1, + outputValue: "mouse" + }] + } + }, + "http://registry\\.gpii\\.net/common/cursorSize": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "mag\\.MouseDoubleSize", + "match": [{ + inputValue: 1, + outputValue: 1 + }, { + inputValue: 0, + outputValue: 0.5 + }] + } + }, + "http://registry\\.gpii\\.net/common/cursorSize": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "mag\\.UnmagnifiedMouseDoubleSize", + "match": [{ + inputValue: 1, + outputValue: 1 + }, { + inputValue: 0, + outputValue: 0.5 + }] + } + }, + "http://registry\\.gpii\\.net/common/showCrosshairs": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "mag\\.MouseCrossHair", + "match": [{ + inputValue: 1, + outputValue: true + }, { + inputValue: 0, + outputValue: false + }] + } + }, + "http://registry\\.gpii\\.net/common/showCrosshairs": { + "transform": { + "type": "fluid.transforms.valueMapper", + "defaultInputPath": "mag\\.UnmagnifiedMouseCrossHair", + "match": [{ + inputValue: 1, + outputValue: true + }, { + inputValue: 0, + outputValue: false + }] + } + } + } + }, + }, + "configure": [ + "settings.configuration1", + "settings.configuration2", + "settings.configuration3" + ], + "restore": [ + "settings.configuration1", + "settings.configuration2", + "settings.configuration3" + ], + "start": [ + { + "type": "gpii.launch.exec", + "command": "\"${{registry}.HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\App Paths\\MAGic131.exe\\}\"" + } + ], + "stop": [ + { + "type": "gpii.windows.closeProcessByName", + "filename": "Magic.exe" + }, + { + "type": "gpii.windows.closeProcessByName", + "filename": "MagHook32.exe" + }, + { + "type": "gpii.windows.closeProcessByName", + "filename": "fsATProxy.exe" + }, + { + "type": "gpii.windows.closeProcessByName", + "filename": "fsWow64Proxy.exe" + }, + { + "type": "gpii.windows.closeProcessByName", + "filename": "mag.exe" + }, + { + "type": "gpii.windows.closeProcessByName", + "filename": "Unloader.exe" + }, + { + "type": "gpii.windows.closeProcessByName", + "filename": "magutil.exe" + } + ], + "isInstalled": [ + { + "type": "gpii.deviceReporter.registryKeyExists", + "hKey": "HKEY_LOCAL_MACHINE", + "path": "Software\\Microsoft\\Windows\\CurrentVersion\\App Paths\\MAGic131.exe", + "subPath": "", + "dataType": "REG_SZ" + } + ] + }, + "com.freedomscientific.jaws": { "name": "JAWS", "contexts": { diff --git a/tests/platform/index-windows.js b/tests/platform/index-windows.js index 4f2ac99a6..624da2b81 100644 --- a/tests/platform/index-windows.js +++ b/tests/platform/index-windows.js @@ -24,6 +24,7 @@ https://github.com/GPII/universal/blob/master/LICENSE.txt module.exports = [ "windows/windows-builtIn-testSpec.js", "windows/windows-jaws-testSpec.js", + "windows/windows-magic-testSpec.js", "windows/windows-nvda-testSpec.js", "windows/windows-maavis-testSpec.js", "windows/windows-chrome-testSpec.js", diff --git a/tests/platform/windows/configs/gpii.tests.acceptance.windows.magic.config.JSON b/tests/platform/windows/configs/gpii.tests.acceptance.windows.magic.config.JSON new file mode 100644 index 000000000..125055136 --- /dev/null +++ b/tests/platform/windows/configs/gpii.tests.acceptance.windows.magic.config.JSON @@ -0,0 +1,13 @@ +{ + "type": "gpii.tests.acceptance.windows.magic.config", + "options": { + "distributeOptions": { + "acceptance.installedSolutionsPath": { + "record": "%universal/testData/deviceReporter/acceptanceTests/magic.json", + "target": "{that deviceReporter installedSolutionsDataSource}.options.path", + "priority": "after:development.installedSolutionsPath" + } + } + }, + "mergeConfigs": "%universal/tests/configs/gpii.tests.acceptance.localInstall.config.json" +} diff --git a/tests/platform/windows/windows-magic-testSpec.js b/tests/platform/windows/windows-magic-testSpec.js new file mode 100644 index 000000000..289fcabdb --- /dev/null +++ b/tests/platform/windows/windows-magic-testSpec.js @@ -0,0 +1,376 @@ +/* + +GPII Acceptance Testing + +Copyright 2014 Raising the Floor International + +Licensed under the New BSD license. You may not use this file except in +compliance with this License. + +The research leading to these results has received funding from the European Union's +Seventh Framework Programme (FP7/2007-2013) under grant agreement no. 289016. + +You may obtain a copy of the License at +https://github.com/GPII/universal/blob/master/LICENSE.txt +*/ + + +"use strict"; +var fluid = require("universal"), + gpii = fluid.registerNamespace("gpii"); + +gpii.loadTestingSupport(); + +fluid.registerNamespace("gpii.tests.windows"); + +gpii.tests.windows.magic = [ + { + name: "Testing NP set \"magic_application\" using Flat matchmaker", + userToken: "magic_application", + settingsHandlers: { + "gpii.settingsHandlers.INISettingsHandler": { + "some.app.id": [ + { + "settings": { + "Voice Profiles.ActiveVoiceProfileName" : "GPII", + "options.SayAllIndicateCaps" : false, + "options.TypingEcho": 3, + "options.SayAllMode": 0, + "options.SayAllIgnoreShiftKeys": true + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.JCF" + } + }, + + { + "settings": { + "mag.startmagnified": 1, + "mag.Size": 1.5, + "mag.TextViewerFontSize": 14, + "mag.TextViewerFontFaceName": "Arial", + "mag.ActiveTracking": 1, + "mag.MouseDoubleSize": 1, + "mag.UnmagnifiedMouseDoubleSize": 1, + "mag.MouseCrossHair": 1, + "mag.UnmagnifiedMouseCrossHair": 1 + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.MCF" + } + }, + + { + "settings": { + "Options.PrimarySynthesizer" : "eloq", + "ENU-Global.Rate": 100, + "ENU-JAWSCursor.Rate": 100, + "ENU-Keyboard.Rate": 100, + "ENU-MenuAndDialog.Rate": 100, + "ENU-Message.Rate": 100, + "ENU-PCCursor.Rate": 100, + "ENU-Global.Pitch": 75, + "ENU-JAWSCursor.Pitch": 75, + "ENU-Keyboard.Pitch": 75, + "ENU-MenuAndDialog.Pitch": 75, + "ENU-Message.Pitch": 75, + "ENU-PCCursor.Pitch": 75, + "ENU-Global.Volume": 100, + "ENU-JAWSCursor.Volume": 100, + "ENU-Keyboard.Volume": 100, + "ENU-MenuAndDialog.Volume": 100, + "ENU-Message.Volume": 100, + "ENU-PCCursor.Volume": 100, + "ENU-Global.Punctuation": 2, + "ENU-JAWSCursor.Punctuation": 2, + "ENU-Keyboard.Punctuation": 2, + "ENU-MenuAndDialog.Punctuation": 2, + "ENU-Message.Punctuation": 2, + "ENU-PCCursor.Punctuation": 2, + "ENU-Global.SynthLangString": "Italian", + "ENU-JAWSCursor.SynthLangString": "Italian", + "ENU-Keyboard.SynthLangString": "Italian", + "ENU-MenuAndDialog.SynthLangString": "Italian", + "ENU-Message.SynthLangString": "Italian", + "ENU-PCCursor.SynthLangString": "Italian" + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\VoiceProfiles\\GPII.VPF" + } + } + ] + } + }, + processes: [ + { + "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq Magic.exe\" | find /I \"Magic.exe\" /C", + "expectConfigured": "1", + "expectRestored": "0", + "maxTimeouts": "40" + } + ] + }, + { + name: "Testing NP set \"magic_common\" using Flat matchmaker", + userToken: "magic_common", + settingsHandlers: { + "gpii.settingsHandlers.INISettingsHandler": { + "some.app.id": [ + { + "settings": { + "Voice Profiles.ActiveVoiceProfileName": "GPII", + "options.SayAllMode": 1, + "options.SayAllIndicateCaps": false, + "options.SayAllIgnoreShiftKeys": false, + "options.TypingEcho": 3 + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.JCF" + } + }, + + { + "settings": { + "mag.startmagnified": 1, + "mag.Size": 1.5, + "mag.TextViewerFontSize": 40, + "mag.TextViewerFontFaceName": "Arial", + "mag.ActiveTracking": 1, + "mag.MouseDoubleSize": 1, + "mag.UnmagnifiedMouseDoubleSize": 1, + "mag.MouseCrossHair": 1, + "mag.UnmagnifiedMouseCrossHair": 1 + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.MCF" + } + }, + + { + "settings": { + "Options.PrimarySynthesizer": "eloq", + "ENU-Global.Rate": 40, + "ENU-Global.Punctuation": 2, + "ENU-Global.Pitch": 75, + "ENU-Global.Volume": 50, + "ENU-Global.SynthLangString": "French", + "ENU-Message.Rate": 40, + "ENU-Message.Punctuation": 2, + "ENU-Message.Pitch": 75, + "ENU-Message.Volume": 50, + "ENU-Message.SynthLangString": "French", + "ENU-Keyboard.Rate": 40, + "ENU-Keyboard.Punctuation": 2, + "ENU-Keyboard.Pitch": 75, + "ENU-Keyboard.Volume": 50, + "ENU-Keyboard.SynthLangString": "French", + "ENU-PCCursor.Rate": 40, + "ENU-PCCursor.Punctuation": 2, + "ENU-PCCursor.Pitch": 75, + "ENU-PCCursor.Volume": 50, + "ENU-PCCursor.SynthLangString": "French", + "ENU-JAWSCursor.Rate": 40, + "ENU-JAWSCursor.Punctuation": 2, + "ENU-JAWSCursor.Pitch": 75, + "ENU-JAWSCursor.Volume": 50, + "ENU-JAWSCursor.SynthLangString": "French", + "ENU-MenuAndDialog.Rate": 40, + "ENU-MenuAndDialog.Punctuation": 2, + "ENU-MenuAndDialog.Pitch": 75, + "ENU-MenuAndDialog.Volume": 50, + "ENU-MenuAndDialog.SynthLangString": "French" + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\VoiceProfiles\\GPII.VPF" + } + } + ] + } + }, + processes: [ + { + "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq Magic.exe\" | find /I \"Magic.exe\" /C", + "expectConfigured": "1", + "expectRestored": "0", + "maxTimeouts": "40" + } + ] + }, + { + name: "Testing NP set \"magic_common2\" using Flat matchmaker", + userToken: "magic_common2", + settingsHandlers: { + "gpii.settingsHandlers.INISettingsHandler": { + "some.app.id": [ + { + "settings": { + "Voice Profiles.ActiveVoiceProfileName": "GPII", + "options.SayAllMode": 0, + "options.SayAllIndicateCaps": false, + "options.SayAllIgnoreShiftKeys": false + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.JCF" + } + }, + + { + "settings": { + "mag.startmagnified" : 1, + "mag.Size" : 2, + "mag.TextViewerFontSize": 30, + "mag.TextViewerFontFaceName": "Arial", + "mag.ActiveTracking": 1, + "mag.MouseDoubleSize": 1, + "mag.UnmagnifiedMouseDoubleSize": 1, + "mag.MouseCrossHair": 1, + "mag.UnmagnifiedMouseCrossHair": 1 + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.MCF" + } + }, + + { + "settings": { + "Options.PrimarySynthesizer": "eloq", + "ENU-Global.Rate": 40, + "ENU-Global.Punctuation": 0, + "ENU-Global.Pitch": 11, + "ENU-Global.Volume": 10, + "ENU-Global.SynthLangString": "Italian", + "ENU-Message.Rate": 40, + "ENU-Message.Punctuation": 0, + "ENU-Message.Pitch": 11, + "ENU-Message.Volume": 10, + "ENU-Message.SynthLangString": "Italian", + "ENU-Keyboard.Rate": 40, + "ENU-Keyboard.Punctuation": 0, + "ENU-Keyboard.Pitch": 11, + "ENU-Keyboard.Volume": 10, + "ENU-Keyboard.SynthLangString": "Italian", + "ENU-PCCursor.Rate": 40, + "ENU-PCCursor.Punctuation": 0, + "ENU-PCCursor.Pitch": 11, + "ENU-PCCursor.Volume": 10, + "ENU-PCCursor.SynthLangString": "Italian", + "ENU-JAWSCursor.Rate": 40, + "ENU-JAWSCursor.Punctuation": 0, + "ENU-JAWSCursor.Pitch": 11, + "ENU-JAWSCursor.Volume": 10, + "ENU-JAWSCursor.SynthLangString": "Italian", + "ENU-MenuAndDialog.Rate": 40, + "ENU-MenuAndDialog.Punctuation": 0, + "ENU-MenuAndDialog.Pitch": 11, + "ENU-MenuAndDialog.Volume": 10, + "ENU-MenuAndDialog.SynthLangString": "Italian" + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\VoiceProfiles\\GPII.VPF" + } + } + ] + } + }, + processes: [ + { + "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq Magic.exe\" | find /I \"Magic.exe\" /C", + "expectConfigured": "1", + "expectRestored": "0", + "maxTimeouts": "40" + } + ] + }, + { + name: "Testing NP set \"magic_common3\" using Flat matchmaker", + userToken: "magic_common3", + settingsHandlers: { + "gpii.settingsHandlers.INISettingsHandler": { + "some.app.id": [ + { + "settings": { + "Voice Profiles.ActiveVoiceProfileName": "GPII", + "options.SayAllMode": 2, + "options.SayAllIndicateCaps": true, + "options.SayAllIgnoreShiftKeys": true, + "options.TypingEcho": 1 + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.JCF" + } + }, + + { + "settings": { + "mag.startmagnified" : 0, + "mag.Size" : 1, + "mag.TextViewerFontSize": 22, + "mag.TextViewerFontFaceName": "Arial", + "mag.MouseDoubleSize": 0, + "mag.UnmagnifiedMouseDoubleSize": 0, + "mag.MouseCrossHair": 0, + "mag.UnmagnifiedMouseCrossHair": 0 + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\enu\\DEFAULT.MCF" + } + }, + + { + "settings": { + "Options.PrimarySynthesizer": "eloq", + "ENU-Global.Rate": 100, + "ENU-Global.Punctuation": 2, + "ENU-Global.Pitch": 100, + "ENU-Global.Volume": 100, + "ENU-Global.SynthLangString": "French Canadian", + "ENU-Message.Rate": 100, + "ENU-Message.Punctuation": 2, + "ENU-Message.Pitch": 100, + "ENU-Message.Volume": 100, + "ENU-Message.SynthLangString": "French Canadian", + "ENU-Keyboard.Rate": 100, + "ENU-Keyboard.Punctuation": 2, + "ENU-Keyboard.Pitch": 100, + "ENU-Keyboard.Volume": 100, + "ENU-Keyboard.SynthLangString": "French Canadian", + "ENU-PCCursor.Rate": 100, + "ENU-PCCursor.Punctuation": 2, + "ENU-PCCursor.Pitch": 100, + "ENU-PCCursor.Volume": 100, + "ENU-PCCursor.SynthLangString": "French Canadian", + "ENU-JAWSCursor.Rate": 100, + "ENU-JAWSCursor.Punctuation": 2, + "ENU-JAWSCursor.Pitch": 100, + "ENU-JAWSCursor.Volume": 100, + "ENU-JAWSCursor.SynthLangString": "French Canadian", + "ENU-MenuAndDialog.Rate": 100, + "ENU-MenuAndDialog.Punctuation": 2, + "ENU-MenuAndDialog.Pitch": 100, + "ENU-MenuAndDialog.Volume": 100, + "ENU-MenuAndDialog.SynthLangString": "French Canadian" + }, + "options": { + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\MAGIC\\13.1\\Settings\\VoiceProfiles\\GPII.VPF" + } + } + ] + } + }, + processes: [ + { + "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq Magic.exe\" | find /I \"Magic.exe\" /C", + "expectConfigured": "1", + "expectRestored": "0", + "maxTimeouts": "40" + } + ] + } +]; + +module.exports = gpii.test.bootstrap({ + testDefs: "gpii.tests.windows.magic", + configName: "gpii.tests.acceptance.windows.magic.config", + configPath: "%universal/tests/platform/windows/configs" +}, ["gpii.test.integration.testCaseHolder.windows"], + module, require, __dirname); diff --git a/tests/platform/windows/windows-magic-testSpec.txt b/tests/platform/windows/windows-magic-testSpec.txt new file mode 100644 index 000000000..8ff73be89 --- /dev/null +++ b/tests/platform/windows/windows-magic-testSpec.txt @@ -0,0 +1,8 @@ +windows-magic-testSpec.js + +Descriptions: +This will run the acceptance tests for the Magic (Freedom Scientific). It uses 4 NP sets: magic_common.json, magic_common2.json, magic_common3.json and magic_application.json + +Prerequisites: +* Magic needs to be installed (Tested with version 13.1) +