Skip to content

Commit

Permalink
SRCH-387 make BingV7 default search engine (#239)
Browse files Browse the repository at this point in the history
* migration: update default for affiliates.search_engine
  • Loading branch information
MothOnMars authored Feb 20, 2019
1 parent a6db54c commit 8a78da7
Show file tree
Hide file tree
Showing 62 changed files with 21,635 additions and 20 deletions.
1 change: 1 addition & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3353,6 +3353,7 @@ Style/MethodCallWithArgsParentheses:
Exclude:
- 'spec/**/*'
- 'Gemfile'
- 'db/**/*'

Style/MethodCallWithoutArgsParentheses:
Description: 'Do not use parentheses for method calls with no arguments.'
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
class ChangeDefaultSearchEngineToBingV7 < ActiveRecord::Migration
def up
change_column_default :affiliates, :search_engine, 'BingV7'
end

def down
change_column_default :affiliates, :search_engine, 'BingV6'
end
end
6 changes: 4 additions & 2 deletions db/structure.sql
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ CREATE TABLE `affiliates` (
`jobs_enabled` tinyint(1) NOT NULL DEFAULT '0',
`agency_id` int(11) DEFAULT NULL,
`raw_log_access_enabled` tinyint(1) NOT NULL DEFAULT '0',
`search_engine` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'BingV6',
`search_engine` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT 'BingV7',
`is_rss_govbox_enabled` tinyint(1) NOT NULL DEFAULT '0',
`rss_govbox_label` varchar(255) COLLATE utf8mb4_unicode_ci NOT NULL,
`is_video_govbox_enabled` tinyint(1) NOT NULL DEFAULT '1',
Expand Down Expand Up @@ -1561,7 +1561,7 @@ CREATE TABLE `youtube_profiles` (
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;

-- Dump completed on 2018-12-17 14:12:16
-- Dump completed on 2019-02-05 12:20:42
INSERT INTO schema_migrations (version) VALUES ('20090818003200');

INSERT INTO schema_migrations (version) VALUES ('20090827135344');
Expand Down Expand Up @@ -3008,3 +3008,5 @@ INSERT INTO schema_migrations (version) VALUES ('20181109212904');

INSERT INTO schema_migrations (version) VALUES ('20181213153332');

INSERT INTO schema_migrations (version) VALUES ('20190205200912');

6 changes: 3 additions & 3 deletions features/admin.feature
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Feature: Administration
And I should see "agency site"
And I should see "agency.gov"
And I should see "www1.agency-site.gov"
And I should see "BingV6"
And I should see "BingV7"
And I should see a link to "beta.agency.gov" with url for "http://beta.agency.gov"

When I follow "www1.agency-site.gov"
Expand Down Expand Up @@ -112,13 +112,13 @@ Feature: Administration
| America IN SPACE | description for space suit item | http://aff.gov//space-suit1 | aff2.gov | 11/02/2011 | OK |
When I go to the admin home page
And I follow "Compare Search Results"
Then I should not see "BingV6 Results"
Then I should not see "BingV7 Results"
And I should not see "ODIE Results"

When I fill in "query" with "america"
When I select "aff.gov" from "Affiliate"
And I press "Search"
Then I should see "BingV6 Results"
Then I should see "BingV7 Results"
And I should see "ODIE Results"
And I should see "Space Suit America"
And I should not see "America IN SPACE"
Expand Down
64 changes: 64 additions & 0 deletions features/vcr_cassettes/Administration/Comparing_Search_Results.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 8a78da7

Please sign in to comment.