From 9b2be26e66bfdc3b893fa18afdff951f90234d80 Mon Sep 17 00:00:00 2001 From: Wayne Date: Mon, 13 Jul 2015 20:44:29 -0500 Subject: [PATCH 1/5] Zoomtext done --- .../acceptanceTests/zoomtext.JSON | 3 + .../deviceReporter/installedSolutions.json | 4 + .../win32_installedSolutions.json | 4 + .../acceptanceTests/zoomtext_application.json | 18 ++++ .../acceptanceTests/zoomtext_common.JSON | 16 ++++ .../preferences/zoomtext_application.json | 18 ++++ testData/preferences/zoomtext_common.JSON | 16 ++++ testData/solutions/win32.json | 63 +++++++++++++ testData/solutions/zoomtext.json | 64 +++++++++++++ tests/platform/index-windows.js | 3 +- .../configs/windows-zoomtext-config.JSON | 21 +++++ .../windows/windows-zoomtext-testSpec.js | 93 +++++++++++++++++++ .../windows/windows-zoomtext-testSpec.txt | 9 ++ 13 files changed, 331 insertions(+), 1 deletion(-) create mode 100644 testData/deviceReporter/acceptanceTests/zoomtext.JSON create mode 100644 testData/preferences/acceptanceTests/zoomtext_application.json create mode 100644 testData/preferences/acceptanceTests/zoomtext_common.JSON create mode 100644 testData/preferences/zoomtext_application.json create mode 100644 testData/preferences/zoomtext_common.JSON create mode 100644 testData/solutions/zoomtext.json create mode 100644 tests/platform/windows/configs/windows-zoomtext-config.JSON create mode 100644 tests/platform/windows/windows-zoomtext-testSpec.js create mode 100644 tests/platform/windows/windows-zoomtext-testSpec.txt diff --git a/testData/deviceReporter/acceptanceTests/zoomtext.JSON b/testData/deviceReporter/acceptanceTests/zoomtext.JSON new file mode 100644 index 000000000..4eaeb442b --- /dev/null +++ b/testData/deviceReporter/acceptanceTests/zoomtext.JSON @@ -0,0 +1,3 @@ +[ + { "id": "com.aisquared.zoomtext" } +] diff --git a/testData/deviceReporter/installedSolutions.json b/testData/deviceReporter/installedSolutions.json index 74fce21b4..852379384 100644 --- a/testData/deviceReporter/installedSolutions.json +++ b/testData/deviceReporter/installedSolutions.json @@ -1,4 +1,8 @@ [ + { + "id": "com.aisquared.zoomtext" + }, + { "id": "org.gnome.desktop.interface" }, diff --git a/testData/deviceReporter/win32_installedSolutions.json b/testData/deviceReporter/win32_installedSolutions.json index 2efbd4d9d..6d849fef6 100644 --- a/testData/deviceReporter/win32_installedSolutions.json +++ b/testData/deviceReporter/win32_installedSolutions.json @@ -4,6 +4,10 @@ "version": "5.0.0" }, "solutions": [ + { + "id": "com.aisquared.zoomtext" + }, + { "id": "org.gnome.desktop.interface" }, diff --git a/testData/preferences/acceptanceTests/zoomtext_application.json b/testData/preferences/acceptanceTests/zoomtext_application.json new file mode 100644 index 000000000..376233200 --- /dev/null +++ b/testData/preferences/acceptanceTests/zoomtext_application.json @@ -0,0 +1,18 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/applications/com.aisquared.zoomtext": { + "ZoomText.ZoomOn": 1, + "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, + "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, + "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, + "PRIMARY.magPower": 300 + } + } + } + } + } +} diff --git a/testData/preferences/acceptanceTests/zoomtext_common.JSON b/testData/preferences/acceptanceTests/zoomtext_common.JSON new file mode 100644 index 000000000..0ea115504 --- /dev/null +++ b/testData/preferences/acceptanceTests/zoomtext_common.JSON @@ -0,0 +1,16 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/common/speechRate": 100, + "http://registry.gpii.net/common/volume": 50, + "http://registry.gpii.net/common/speechEnabled": "on", + "http://registry.gpii.net/common/magnifierEnabled": 1, + "http://registry.gpii.net/common/magnification": 300 + } + } + } + } +} diff --git a/testData/preferences/zoomtext_application.json b/testData/preferences/zoomtext_application.json new file mode 100644 index 000000000..376233200 --- /dev/null +++ b/testData/preferences/zoomtext_application.json @@ -0,0 +1,18 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/applications/com.aisquared.zoomtext": { + "ZoomText.ZoomOn": 1, + "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, + "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, + "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, + "PRIMARY.magPower": 300 + } + } + } + } + } +} diff --git a/testData/preferences/zoomtext_common.JSON b/testData/preferences/zoomtext_common.JSON new file mode 100644 index 000000000..0ea115504 --- /dev/null +++ b/testData/preferences/zoomtext_common.JSON @@ -0,0 +1,16 @@ +{ + "flat": { + "contexts": { + "gpii-default": { + "name": "Default preferences", + "preferences": { + "http://registry.gpii.net/common/speechRate": 100, + "http://registry.gpii.net/common/volume": 50, + "http://registry.gpii.net/common/speechEnabled": "on", + "http://registry.gpii.net/common/magnifierEnabled": 1, + "http://registry.gpii.net/common/magnification": 300 + } + } + } + } +} diff --git a/testData/solutions/win32.json b/testData/solutions/win32.json index 035159da3..f0ae4f967 100644 --- a/testData/solutions/win32.json +++ b/testData/solutions/win32.json @@ -1,4 +1,67 @@ { + "com.aisquared.zoomtext": { + "name": "ZoomText", + "contexts": { + "OS": [ + { + "id": "win32" + } + ] + }, + "settingsHandlers": [ + { + "type": "gpii.settingsHandlers.INISettingsHandler", + "options": { + "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" + }, + "capabilities": [ + "applications.com\\.aisquared\\.zoomtext.id", + "display.screenReader.speechRate", + "display.screenEnhancement.-provisional-magnifierEnabled", + "display.screenEnhancement.magnification", + "-provisional-general.-provisional-volume" + ], + + "capabilitiesTransformations": { + "ZoomText\\.ZoomOn": "http://registry\\.gpii\\.net/common/magnifierEnabled", + "PRIMARY\\.magPower": "http://registry\\.gpii\\.net/common/magnification", + "ZT English, United States (Paul) Speech - Screen Reader\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ZT English, United States (Paul) Speech - Screen Reader\\.Volume": "http://registry\\.gpii\\.net/common/volume", + "ZT English, United States (Paul) Speech - Screen Reader\\.Muted": { + "transform": { + "type": "fluid.transforms.valueMapper", + "inputPath": "http://registry\\.gpii\\.net/common/speechEnabled", + "options": { + "on": { + "outputValue": 0 + }, + "off": { + "outputValue": 1 + } + } + } + } + } + } + ], + "lifecycleManager": { + "start": [ + "setSettings", + { + "type": "gpii.launch.exec", + "command": "\"C:\\Program Files (x86)\\ZoomText 10.1\\Zt.exe\"" + } + ], + "stop": [ + { + "type": "gpii.launch.exec", + "command": "${{environment}.SystemRoot}\\System32\\taskkill.exe /f /im Zt.exe" + }, + "restoreSettings" + ] + } + }, + "com.freedomscientific.jaws": { "name": "JAWS", "contexts": { diff --git a/testData/solutions/zoomtext.json b/testData/solutions/zoomtext.json new file mode 100644 index 000000000..55808311a --- /dev/null +++ b/testData/solutions/zoomtext.json @@ -0,0 +1,64 @@ +{ + "com.aisquared.zoomtext": { + "name": "ZoomText", + "contexts": { + "OS": [ + { + "id": "win32" + } + ] + }, + "settingsHandlers": [ + { + "type": "gpii.settingsHandlers.INISettingsHandler", + "options": { + "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" + }, + "capabilities": [ + "applications.com\\.aisquared\\.zoomtext.id", + "display.screenReader.speechRate", + "display.screenEnhancement.-provisional-magnifierEnabled", + "display.screenEnhancement.magnification", + "-provisional-general.-provisional-volume" + ], + + "capabilitiesTransformations": { + "ZoomText\\.ZoomOn": "http://registry\\.gpii\\.net/common/magnifierEnabled", + "PRIMARY\\.magPower": "http://registry\\.gpii\\.net/common/magnification", + "ZT English, United States (Paul) Speech - Screen Reader\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", + "ZT English, United States (Paul) Speech - Screen Reader\\.Volume": "http://registry\\.gpii\\.net/common/volume", + "ZT English, United States (Paul) Speech - Screen Reader\\.Muted": { + "transform": { + "type": "fluid.transforms.valueMapper", + "inputPath": "http://registry\\.gpii\\.net/common/speechEnabled", + "options": { + "on": { + "outputValue": 0 + }, + "off": { + "outputValue": 1 + } + } + } + } + } + } + ], + "lifecycleManager": { + "start": [ + "setSettings", + { + "type": "gpii.launch.exec", + "command": "\"C:\\Program Files (x86)\\ZoomText 10.1\\Zt.exe\"" + } + ], + "stop": [ + { + "type": "gpii.launch.exec", + "command": "${{environment}.SystemRoot}\\System32\\taskkill.exe /f /im Zt.exe" + }, + "restoreSettings" + ] + } + } +} \ No newline at end of file diff --git a/tests/platform/index-windows.js b/tests/platform/index-windows.js index 964bcfa6b..a0658ac83 100644 --- a/tests/platform/index-windows.js +++ b/tests/platform/index-windows.js @@ -23,5 +23,6 @@ module.exports = [ "windows/windows-builtIn-testSpec.js", "windows/windows-jaws-testSpec.js", "windows/windows-nvda-testSpec.js", - "windows/windows-maavis-testSpec.js" + "windows/windows-maavis-testSpec.js", + "windows/windows-zoomtext-testSpec.js" ]; \ No newline at end of file diff --git a/tests/platform/windows/configs/windows-zoomtext-config.JSON b/tests/platform/windows/configs/windows-zoomtext-config.JSON new file mode 100644 index 000000000..e9faef851 --- /dev/null +++ b/tests/platform/windows/configs/windows-zoomtext-config.JSON @@ -0,0 +1,21 @@ +{ + "typeName": "acceptanceTests.windows.zoomtext", + "options": { + "components": { + "server": { + "options": { + "components": { + "deviceReporter": { + "options": { + "installedSolutionsUrl": "file://%root/../../../testData/deviceReporter/acceptanceTests/zoomtext.json" + } + } + } + } + } + } + }, + "includes": [ + "${universal}/tests/configs/localInstall.json" + ] +} diff --git a/tests/platform/windows/windows-zoomtext-testSpec.js b/tests/platform/windows/windows-zoomtext-testSpec.js new file mode 100644 index 000000000..0f595bdf5 --- /dev/null +++ b/tests/platform/windows/windows-zoomtext-testSpec.js @@ -0,0 +1,93 @@ +/* + +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.zoomtext = [ + { + name: "Testing NP set \"zoomtext_application\" using Flat matchmaker", + userToken: "zoomtext_application", + settingsHandlers: { + "gpii.settingsHandlers.INISettingsHandler": { + "some.app.id": [ + { + "settings": { + "ZoomText.ZoomOn": 1, + "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, + "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, + "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, + "PRIMARY.magPower": 300 + }, + "options": { + "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" + } + } + ] + } + }, + processes: [ + { + "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq zt.exe\" | find /I \"zt.exe\" /C", + "expectConfigured": "1", + "expectRestored": "0" + } + ] + }, + + { + name: "Testing NP set \"zoomtext_common\" using Flat matchmaker", + userToken: "zoomtext_common", + settingsHandlers: { + "gpii.settingsHandlers.INISettingsHandler": { + "some.app.id": [ + { + "settings": { + "ZoomText.ZoomOn": 1, + "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, + "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, + "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, + "PRIMARY.magPower": 300 + }, + "options": { + "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" + } + } + ] + } + }, + processes: [ + { + "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq zt.exe\" | find /I \"zt.exe\" /C", + "expectConfigured": "1", + "expectRestored": "0" + } + ] + } +]; + +module.exports = gpii.test.bootstrap({ + testDefs: "gpii.tests.windows.zoomtext", + configName: "windows-zoomtext-config", + configPath: "configs" +}, ["gpii.test.integration.testCaseHolder.windows"], + module, require, __dirname); diff --git a/tests/platform/windows/windows-zoomtext-testSpec.txt b/tests/platform/windows/windows-zoomtext-testSpec.txt new file mode 100644 index 000000000..97a687269 --- /dev/null +++ b/tests/platform/windows/windows-zoomtext-testSpec.txt @@ -0,0 +1,9 @@ +windows-zoomtext-testSpec.js + +Descriptions: +This will run the acceptance tests for the ZoomText (AiSquared). It uses 2 NP sets: zoomtext_common.json and zoomtext_application.json + +Prerequisites: +* ZoomText needs to be installed +* ZoomText has to be installed in the default location "C:\\Program Files (x86)\\ZoomText 10.1 + From 6225ba7e87c0a332a2eb13d19d3b6cd42dac956d Mon Sep 17 00:00:00 2001 From: Wayne Date: Mon, 13 Jul 2015 20:52:01 -0500 Subject: [PATCH 2/5] revert changes --- .../acceptanceTests/zoomtext.JSON | 3 - .../deviceReporter/installedSolutions.json | 4 - .../win32_installedSolutions.json | 4 - .../acceptanceTests/zoomtext_application.json | 18 ---- .../acceptanceTests/zoomtext_common.JSON | 16 --- .../preferences/zoomtext_application.json | 18 ---- testData/preferences/zoomtext_common.JSON | 16 --- testData/solutions/win32.json | 97 +++++++++---------- testData/solutions/zoomtext.json | 64 ------------ tests/platform/index-windows.js | 3 +- .../configs/windows-zoomtext-config.JSON | 21 ---- .../windows/windows-zoomtext-testSpec.js | 93 ------------------ .../windows/windows-zoomtext-testSpec.txt | 9 -- 13 files changed, 45 insertions(+), 321 deletions(-) delete mode 100644 testData/deviceReporter/acceptanceTests/zoomtext.JSON delete mode 100644 testData/preferences/acceptanceTests/zoomtext_application.json delete mode 100644 testData/preferences/acceptanceTests/zoomtext_common.JSON delete mode 100644 testData/preferences/zoomtext_application.json delete mode 100644 testData/preferences/zoomtext_common.JSON delete mode 100644 testData/solutions/zoomtext.json delete mode 100644 tests/platform/windows/configs/windows-zoomtext-config.JSON delete mode 100644 tests/platform/windows/windows-zoomtext-testSpec.js delete mode 100644 tests/platform/windows/windows-zoomtext-testSpec.txt diff --git a/testData/deviceReporter/acceptanceTests/zoomtext.JSON b/testData/deviceReporter/acceptanceTests/zoomtext.JSON deleted file mode 100644 index 4eaeb442b..000000000 --- a/testData/deviceReporter/acceptanceTests/zoomtext.JSON +++ /dev/null @@ -1,3 +0,0 @@ -[ - { "id": "com.aisquared.zoomtext" } -] diff --git a/testData/deviceReporter/installedSolutions.json b/testData/deviceReporter/installedSolutions.json index 852379384..74fce21b4 100644 --- a/testData/deviceReporter/installedSolutions.json +++ b/testData/deviceReporter/installedSolutions.json @@ -1,8 +1,4 @@ [ - { - "id": "com.aisquared.zoomtext" - }, - { "id": "org.gnome.desktop.interface" }, diff --git a/testData/deviceReporter/win32_installedSolutions.json b/testData/deviceReporter/win32_installedSolutions.json index 6d849fef6..2efbd4d9d 100644 --- a/testData/deviceReporter/win32_installedSolutions.json +++ b/testData/deviceReporter/win32_installedSolutions.json @@ -4,10 +4,6 @@ "version": "5.0.0" }, "solutions": [ - { - "id": "com.aisquared.zoomtext" - }, - { "id": "org.gnome.desktop.interface" }, diff --git a/testData/preferences/acceptanceTests/zoomtext_application.json b/testData/preferences/acceptanceTests/zoomtext_application.json deleted file mode 100644 index 376233200..000000000 --- a/testData/preferences/acceptanceTests/zoomtext_application.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "flat": { - "contexts": { - "gpii-default": { - "name": "Default preferences", - "preferences": { - "http://registry.gpii.net/applications/com.aisquared.zoomtext": { - "ZoomText.ZoomOn": 1, - "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, - "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, - "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, - "PRIMARY.magPower": 300 - } - } - } - } - } -} diff --git a/testData/preferences/acceptanceTests/zoomtext_common.JSON b/testData/preferences/acceptanceTests/zoomtext_common.JSON deleted file mode 100644 index 0ea115504..000000000 --- a/testData/preferences/acceptanceTests/zoomtext_common.JSON +++ /dev/null @@ -1,16 +0,0 @@ -{ - "flat": { - "contexts": { - "gpii-default": { - "name": "Default preferences", - "preferences": { - "http://registry.gpii.net/common/speechRate": 100, - "http://registry.gpii.net/common/volume": 50, - "http://registry.gpii.net/common/speechEnabled": "on", - "http://registry.gpii.net/common/magnifierEnabled": 1, - "http://registry.gpii.net/common/magnification": 300 - } - } - } - } -} diff --git a/testData/preferences/zoomtext_application.json b/testData/preferences/zoomtext_application.json deleted file mode 100644 index 376233200..000000000 --- a/testData/preferences/zoomtext_application.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "flat": { - "contexts": { - "gpii-default": { - "name": "Default preferences", - "preferences": { - "http://registry.gpii.net/applications/com.aisquared.zoomtext": { - "ZoomText.ZoomOn": 1, - "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, - "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, - "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, - "PRIMARY.magPower": 300 - } - } - } - } - } -} diff --git a/testData/preferences/zoomtext_common.JSON b/testData/preferences/zoomtext_common.JSON deleted file mode 100644 index 0ea115504..000000000 --- a/testData/preferences/zoomtext_common.JSON +++ /dev/null @@ -1,16 +0,0 @@ -{ - "flat": { - "contexts": { - "gpii-default": { - "name": "Default preferences", - "preferences": { - "http://registry.gpii.net/common/speechRate": 100, - "http://registry.gpii.net/common/volume": 50, - "http://registry.gpii.net/common/speechEnabled": "on", - "http://registry.gpii.net/common/magnifierEnabled": 1, - "http://registry.gpii.net/common/magnification": 300 - } - } - } - } -} diff --git a/testData/solutions/win32.json b/testData/solutions/win32.json index f0ae4f967..5171fa332 100644 --- a/testData/solutions/win32.json +++ b/testData/solutions/win32.json @@ -1,6 +1,6 @@ { - "com.aisquared.zoomtext": { - "name": "ZoomText", + "com.freedomscientific.jaws": { + "name": "JAWS", "contexts": { "OS": [ { @@ -12,76 +12,50 @@ { "type": "gpii.settingsHandlers.INISettingsHandler", "options": { - "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\JAWS\\16.0\\Settings\\enu\\DEFAULT.JCF" }, "capabilities": [ - "applications.com\\.aisquared\\.zoomtext.id", - "display.screenReader.speechRate", - "display.screenEnhancement.-provisional-magnifierEnabled", - "display.screenEnhancement.magnification", - "-provisional-general.-provisional-volume" + "applications.com\\.freedomscientific\\.jaws.id" ], "capabilitiesTransformations": { - "ZoomText\\.ZoomOn": "http://registry\\.gpii\\.net/common/magnifierEnabled", - "PRIMARY\\.magPower": "http://registry\\.gpii\\.net/common/magnification", - "ZT English, United States (Paul) Speech - Screen Reader\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", - "ZT English, United States (Paul) Speech - Screen Reader\\.Volume": "http://registry\\.gpii\\.net/common/volume", - "ZT English, United States (Paul) Speech - Screen Reader\\.Muted": { + "Voice Profiles\\.ActiveVoiceProfileName": { + "transform": { + "type": "fluid.transforms.literalValue", + "inputPath": "http://registry\\.gpii\\.net/common/voiceProfile", + "value": "GPII" + } + }, + "options\\.TypingEcho": { "transform": { "type": "fluid.transforms.valueMapper", - "inputPath": "http://registry\\.gpii\\.net/common/speechEnabled", + "inputPath": "http://registry\\.gpii\\.net/common/typingEcho", "options": { "on": { - "outputValue": 0 + "outputValue": 1 }, "off": { - "outputValue": 1 + "outputValue": 0 } } } } } - } - ], - "lifecycleManager": { - "start": [ - "setSettings", - { - "type": "gpii.launch.exec", - "command": "\"C:\\Program Files (x86)\\ZoomText 10.1\\Zt.exe\"" - } - ], - "stop": [ - { - "type": "gpii.launch.exec", - "command": "${{environment}.SystemRoot}\\System32\\taskkill.exe /f /im Zt.exe" - }, - "restoreSettings" - ] - } - }, - - "com.freedomscientific.jaws": { - "name": "JAWS", - "contexts": { - "OS": [ - { - "id": "win32" - } - ] - }, - "settingsHandlers": [ + }, + { "type": "gpii.settingsHandlers.INISettingsHandler", "options": { - "filename": "${{environment}.APPDATA}\\Freedom Scientific\\JAWS\\15.0\\Settings\\VoiceProfiles.ini" + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\JAWS\\16.0\\Settings\\VoiceProfiles\\GPII.VPF" }, "capabilities": [ - "applications.com\\.freedomscientific\\.jaws.id" + "applications.com\\.freedomscientific\\.jaws.id", + "display.screenReader.-provisional-punctuationVerbosity", + "display.screenReader.speechRate", + "display.textReadingHighlight.pitch" ], "capabilitiesTransformations": { - "cloud4allVoiceProfile-GlobalContext\\.Punctuation": { + "ENU-Global\\.Punctuation": { "transform": { "type": "fluid.transforms.valueMapper", "inputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", @@ -101,7 +75,24 @@ } } }, - "cloud4allVoiceProfile-GlobalContext\\.Speed": { + "ENU-Global\\.Pitch":{ + "transform": { + "type": "fluid.transforms.valueMapper", + "inputPath": "http://registry\\.gpii\\.net/common/pitch", + "options": { + "low": { + "outputValue": 25 + }, + "medium": { + "outputValue": 75 + }, + "high": { + "outputValue": 125 + } + } + } + }, + "ENU-Global\\.Rate": { "transform": { "type": "fluid.transforms.linearScale", "valuePath": "http://registry\\.gpii\\.net/common/speechRate", @@ -117,13 +108,13 @@ "setSettings", { "type": "gpii.launch.exec", - "command": "\"${{registry}.HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\App Paths\\JAWS15.exe\\}\"" + "command": "\"${{registry}.HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\App Paths\\JAWS16.exe\\}\"" } ], "stop": [ { - "type": "gpii.windows.killProcessByName", - "filename": "jfw.exe" + "type": "gpii.launch.exec", + "command": "${{environment}.SystemRoot}\\System32\\taskkill.exe /f /im jfw.exe" }, "restoreSettings" ] diff --git a/testData/solutions/zoomtext.json b/testData/solutions/zoomtext.json deleted file mode 100644 index 55808311a..000000000 --- a/testData/solutions/zoomtext.json +++ /dev/null @@ -1,64 +0,0 @@ -{ - "com.aisquared.zoomtext": { - "name": "ZoomText", - "contexts": { - "OS": [ - { - "id": "win32" - } - ] - }, - "settingsHandlers": [ - { - "type": "gpii.settingsHandlers.INISettingsHandler", - "options": { - "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" - }, - "capabilities": [ - "applications.com\\.aisquared\\.zoomtext.id", - "display.screenReader.speechRate", - "display.screenEnhancement.-provisional-magnifierEnabled", - "display.screenEnhancement.magnification", - "-provisional-general.-provisional-volume" - ], - - "capabilitiesTransformations": { - "ZoomText\\.ZoomOn": "http://registry\\.gpii\\.net/common/magnifierEnabled", - "PRIMARY\\.magPower": "http://registry\\.gpii\\.net/common/magnification", - "ZT English, United States (Paul) Speech - Screen Reader\\.Rate": "http://registry\\.gpii\\.net/common/speechRate", - "ZT English, United States (Paul) Speech - Screen Reader\\.Volume": "http://registry\\.gpii\\.net/common/volume", - "ZT English, United States (Paul) Speech - Screen Reader\\.Muted": { - "transform": { - "type": "fluid.transforms.valueMapper", - "inputPath": "http://registry\\.gpii\\.net/common/speechEnabled", - "options": { - "on": { - "outputValue": 0 - }, - "off": { - "outputValue": 1 - } - } - } - } - } - } - ], - "lifecycleManager": { - "start": [ - "setSettings", - { - "type": "gpii.launch.exec", - "command": "\"C:\\Program Files (x86)\\ZoomText 10.1\\Zt.exe\"" - } - ], - "stop": [ - { - "type": "gpii.launch.exec", - "command": "${{environment}.SystemRoot}\\System32\\taskkill.exe /f /im Zt.exe" - }, - "restoreSettings" - ] - } - } -} \ No newline at end of file diff --git a/tests/platform/index-windows.js b/tests/platform/index-windows.js index a0658ac83..964bcfa6b 100644 --- a/tests/platform/index-windows.js +++ b/tests/platform/index-windows.js @@ -23,6 +23,5 @@ module.exports = [ "windows/windows-builtIn-testSpec.js", "windows/windows-jaws-testSpec.js", "windows/windows-nvda-testSpec.js", - "windows/windows-maavis-testSpec.js", - "windows/windows-zoomtext-testSpec.js" + "windows/windows-maavis-testSpec.js" ]; \ No newline at end of file diff --git a/tests/platform/windows/configs/windows-zoomtext-config.JSON b/tests/platform/windows/configs/windows-zoomtext-config.JSON deleted file mode 100644 index e9faef851..000000000 --- a/tests/platform/windows/configs/windows-zoomtext-config.JSON +++ /dev/null @@ -1,21 +0,0 @@ -{ - "typeName": "acceptanceTests.windows.zoomtext", - "options": { - "components": { - "server": { - "options": { - "components": { - "deviceReporter": { - "options": { - "installedSolutionsUrl": "file://%root/../../../testData/deviceReporter/acceptanceTests/zoomtext.json" - } - } - } - } - } - } - }, - "includes": [ - "${universal}/tests/configs/localInstall.json" - ] -} diff --git a/tests/platform/windows/windows-zoomtext-testSpec.js b/tests/platform/windows/windows-zoomtext-testSpec.js deleted file mode 100644 index 0f595bdf5..000000000 --- a/tests/platform/windows/windows-zoomtext-testSpec.js +++ /dev/null @@ -1,93 +0,0 @@ -/* - -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.zoomtext = [ - { - name: "Testing NP set \"zoomtext_application\" using Flat matchmaker", - userToken: "zoomtext_application", - settingsHandlers: { - "gpii.settingsHandlers.INISettingsHandler": { - "some.app.id": [ - { - "settings": { - "ZoomText.ZoomOn": 1, - "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, - "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, - "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, - "PRIMARY.magPower": 300 - }, - "options": { - "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" - } - } - ] - } - }, - processes: [ - { - "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq zt.exe\" | find /I \"zt.exe\" /C", - "expectConfigured": "1", - "expectRestored": "0" - } - ] - }, - - { - name: "Testing NP set \"zoomtext_common\" using Flat matchmaker", - userToken: "zoomtext_common", - settingsHandlers: { - "gpii.settingsHandlers.INISettingsHandler": { - "some.app.id": [ - { - "settings": { - "ZoomText.ZoomOn": 1, - "ZT English, United States (Paul) Speech - Screen Reader.Rate": 100, - "ZT English, United States (Paul) Speech - Screen Reader.Volume": 50, - "ZT English, United States (Paul) Speech - Screen Reader.Muted": 0, - "PRIMARY.magPower": 300 - }, - "options": { - "filename": "C:\\Program Files (x86)\\ZoomText 10.1\\Config\\users\\user\\zten-US.zxc" - } - } - ] - } - }, - processes: [ - { - "command": "tasklist /fi \"STATUS eq RUNNING\" /FI \"IMAGENAME eq zt.exe\" | find /I \"zt.exe\" /C", - "expectConfigured": "1", - "expectRestored": "0" - } - ] - } -]; - -module.exports = gpii.test.bootstrap({ - testDefs: "gpii.tests.windows.zoomtext", - configName: "windows-zoomtext-config", - configPath: "configs" -}, ["gpii.test.integration.testCaseHolder.windows"], - module, require, __dirname); diff --git a/tests/platform/windows/windows-zoomtext-testSpec.txt b/tests/platform/windows/windows-zoomtext-testSpec.txt deleted file mode 100644 index 97a687269..000000000 --- a/tests/platform/windows/windows-zoomtext-testSpec.txt +++ /dev/null @@ -1,9 +0,0 @@ -windows-zoomtext-testSpec.js - -Descriptions: -This will run the acceptance tests for the ZoomText (AiSquared). It uses 2 NP sets: zoomtext_common.json and zoomtext_application.json - -Prerequisites: -* ZoomText needs to be installed -* ZoomText has to be installed in the default location "C:\\Program Files (x86)\\ZoomText 10.1 - From 65568383f52524e05f80724fab930ce4053c2343 Mon Sep 17 00:00:00 2001 From: Wayne Date: Mon, 13 Jul 2015 20:56:59 -0500 Subject: [PATCH 3/5] revert changes --- testData/solutions/win32.json | 68 ++++------------------------------- 1 file changed, 7 insertions(+), 61 deletions(-) diff --git a/testData/solutions/win32.json b/testData/solutions/win32.json index 5171fa332..4201fb311 100644 --- a/testData/solutions/win32.json +++ b/testData/solutions/win32.json @@ -12,50 +12,13 @@ { "type": "gpii.settingsHandlers.INISettingsHandler", "options": { - "filename": "${{environment}.APPDATA}\\Freedom Scientific\\JAWS\\16.0\\Settings\\enu\\DEFAULT.JCF" + "filename": "${{environment}.APPDATA}\\Freedom Scientific\\JAWS\\15.0\\Settings\\VoiceProfiles.ini" }, "capabilities": [ "applications.com\\.freedomscientific\\.jaws.id" ], - "capabilitiesTransformations": { - "Voice Profiles\\.ActiveVoiceProfileName": { - "transform": { - "type": "fluid.transforms.literalValue", - "inputPath": "http://registry\\.gpii\\.net/common/voiceProfile", - "value": "GPII" - } - }, - "options\\.TypingEcho": { - "transform": { - "type": "fluid.transforms.valueMapper", - "inputPath": "http://registry\\.gpii\\.net/common/typingEcho", - "options": { - "on": { - "outputValue": 1 - }, - "off": { - "outputValue": 0 - } - } - } - } - } - }, - - { - "type": "gpii.settingsHandlers.INISettingsHandler", - "options": { - "filename": "${{environment}.APPDATA}\\Freedom Scientific\\JAWS\\16.0\\Settings\\VoiceProfiles\\GPII.VPF" - }, - "capabilities": [ - "applications.com\\.freedomscientific\\.jaws.id", - "display.screenReader.-provisional-punctuationVerbosity", - "display.screenReader.speechRate", - "display.textReadingHighlight.pitch" - ], - "capabilitiesTransformations": { - "ENU-Global\\.Punctuation": { + "cloud4allVoiceProfile-GlobalContext\\.Punctuation": { "transform": { "type": "fluid.transforms.valueMapper", "inputPath": "http://registry\\.gpii\\.net/common/punctuationVerbosity", @@ -75,24 +38,7 @@ } } }, - "ENU-Global\\.Pitch":{ - "transform": { - "type": "fluid.transforms.valueMapper", - "inputPath": "http://registry\\.gpii\\.net/common/pitch", - "options": { - "low": { - "outputValue": 25 - }, - "medium": { - "outputValue": 75 - }, - "high": { - "outputValue": 125 - } - } - } - }, - "ENU-Global\\.Rate": { + "cloud4allVoiceProfile-GlobalContext\\.Speed": { "transform": { "type": "fluid.transforms.linearScale", "valuePath": "http://registry\\.gpii\\.net/common/speechRate", @@ -108,13 +54,13 @@ "setSettings", { "type": "gpii.launch.exec", - "command": "\"${{registry}.HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\App Paths\\JAWS16.exe\\}\"" + "command": "\"${{registry}.HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\App Paths\\JAWS15.exe\\}\"" } ], "stop": [ { - "type": "gpii.launch.exec", - "command": "${{environment}.SystemRoot}\\System32\\taskkill.exe /f /im jfw.exe" + "type": "gpii.windows.killProcessByName", + "filename": "jfw.exe" }, "restoreSettings" ] @@ -1373,4 +1319,4 @@ ] } } -} +} \ No newline at end of file From f9ff6641e63ed287168fbd68b4393110b57fb1bd Mon Sep 17 00:00:00 2001 From: Wayne Date: Mon, 13 Jul 2015 21:07:37 -0500 Subject: [PATCH 4/5] add newline --- testData/solutions/win32.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testData/solutions/win32.json b/testData/solutions/win32.json index 4201fb311..035159da3 100644 --- a/testData/solutions/win32.json +++ b/testData/solutions/win32.json @@ -1319,4 +1319,4 @@ ] } } -} \ No newline at end of file +} From d6bc225614c33162c6796e8cb5afa8cd3364d547 Mon Sep 17 00:00:00 2001 From: Wayne Date: Wed, 15 Jul 2015 15:00:34 -0500 Subject: [PATCH 5/5] Check File done --- .../settingsHandlers/src/settingsHandlerUtilities.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/gpii/node_modules/settingsHandlers/src/settingsHandlerUtilities.js b/gpii/node_modules/settingsHandlers/src/settingsHandlerUtilities.js index d00a0575b..041be80e2 100644 --- a/gpii/node_modules/settingsHandlers/src/settingsHandlerUtilities.js +++ b/gpii/node_modules/settingsHandlers/src/settingsHandlerUtilities.js @@ -338,6 +338,11 @@ gpii.settingsHandlers.writeFile = function (content, options) { gpii.settingsHandlers.handleFileSolutionEntry = function (solutionEntry, modifier, parser, isWrite) { var options = solutionEntry.options; + //create empty file, if file does not exist + if (!fs.existsSync(options.filename)) { + gpii.settingsHandlers.writeFile("", options); + } + if (options && (options.path || options.filename)) { // read file var content = gpii.settingsHandlers.readFile(options); @@ -377,4 +382,4 @@ gpii.settingsHandlers.makeFileSet = function (parser) { return gpii.settingsHandlers.transformFilePayload(payload, gpii.settingsHandlers.setSettings, parser, true); }; }; - + \ No newline at end of file