Navigation Menu

Skip to content

Commit

Permalink
Update output format of index field status
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Aug 9, 2012
1 parent 903d135 commit 412fb43
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 9 deletions.
2 changes: 1 addition & 1 deletion lib/database/index-field.js
Expand Up @@ -140,7 +140,7 @@ IndexField.prototype = {
},

get facetEnabled() {
return this.type != 'text';
return this.type != 'uint';
},

get resultEnabled() {
Expand Down
22 changes: 14 additions & 8 deletions test/database-index-field.test.js
Expand Up @@ -101,12 +101,14 @@ suite('database', function() {
facetEnabled: field.facetEnabled,
resultEnabled: field.resultEnabled,
searchEnabled: field.searchEnabled,
state: field.state
state: field.state,
options: field.options
}, {
facetEnabled: false,
facetEnabled: true,
resultEnabled: true,
searchEnabled: true,
state: 'Active'
state: 'Active',
options: 'Search Facet Result'
});
});

Expand All @@ -117,12 +119,14 @@ suite('database', function() {
facetEnabled: field.facetEnabled,
resultEnabled: field.resultEnabled,
searchEnabled: field.searchEnabled,
state: field.state
state: field.state,
options: field.options
}, {
facetEnabled: true,
facetEnabled: false,
resultEnabled: true,
searchEnabled: true,
state: 'Active'
state: 'Active',
options: 'Search Result'
});
});

Expand All @@ -133,12 +137,14 @@ suite('database', function() {
facetEnabled: field.facetEnabled,
resultEnabled: field.resultEnabled,
searchEnabled: field.searchEnabled,
state: field.state
state: field.state,
options: field.options
}, {
facetEnabled: true,
resultEnabled: true,
searchEnabled: true,
state: 'Active'
state: 'Active',
options: 'Search Facet Result'
});
});

Expand Down

0 comments on commit 412fb43

Please sign in to comment.