Bug 1009318 - Add Google search purpose for about:newtab. r=MattN

This commit is contained in:
Drew Willcoxon 2014-05-13 12:37:19 -07:00
Родитель b25bc9207e
Коммит 165dac9371
3 изменённых файлов: 9 добавлений и 1 удалений

Просмотреть файл

@ -67,6 +67,8 @@ function test() {
is(url, base + "&channel=sb", "Check search bar search URL for 'foo'");
url = engine.getSubmission("foo", null, "homepage").uri.spec;
is(url, base + "&channel=np&source=hp", "Check homepage search URL for 'foo'");
url = engine.getSubmission("foo", null, "newtab").uri.spec;
is(url, base + "&channel=nts", "Check newtab search URL for 'foo'");
// Check search suggestion URL.
url = engine.getSubmission("foo", "application/x-suggestions+json").uri.spec;
@ -145,6 +147,11 @@ function test() {
"value": "np",
"purpose": "homepage",
},
{
"name": "channel",
"value": "nts",
"purpose": "newtab",
},
{
"name": "source",
"value": "hp",

Просмотреть файл

@ -97,7 +97,7 @@ function test() {
},
{
name: "new tab search",
searchURL: base,
searchURL: base + "&channel=nts",
run: function () {
function doSearch(doc) {
// Re-add the listener, and perform a search

Просмотреть файл

@ -27,6 +27,7 @@
<MozParam name="channel" condition="purpose" purpose="keyword" value="fflb"/>
<MozParam name="channel" condition="purpose" purpose="searchbar" value="sb"/>
<MozParam name="channel" condition="purpose" purpose="homepage" value="np"/>
<MozParam name="channel" condition="purpose" purpose="newtab" value="nts"/>
<MozParam name="source" condition="purpose" purpose="homepage" value="hp"/>
</Url>
<Url type="text/html" method="GET" template="https://www.google.com/" rel="searchform"/>