YUKI Hiroshi
null+****@clear*****
Thu Nov 1 11:36:13 JST 2012
YUKI Hiroshi 2012-11-01 11:36:13 +0900 (Thu, 01 Nov 2012) New Revision: 21adec6197bba05a6eebaf09402ab61f246078d2 https://github.com/groonga/gcs/commit/21adec6197bba05a6eebaf09402ab61f246078d2 Log: Add test for Domain#searchableDocumentsCount Modified files: test/database-domain.test.js Modified: test/database-domain.test.js (+16 -0) =================================================================== --- test/database-domain.test.js 2012-11-01 11:29:07 +0900 (f81b3b5) +++ test/database-domain.test.js 2012-11-01 11:36:13 +0900 (caff485) @@ -753,6 +753,22 @@ suite('database', function() { ]; assert.deepEqual(actualDump.slice(-2), expectedDump); }); + + test('searchableDocumentsCount', function() { + assert.equal(domain.searchableDocumentsCount, 0); + + utils.loadDumpFile(context, __dirname + '/fixture/companies/data.grn'); + assert.equal(domain.searchableDocumentsCount, 10); + + var values = [ + { id: 'id11', + description: 'new', + name: 'Nergal Heavy Industries', + product: 'nadesico' } + ]; + domain.loadSync(values); + assert.equal(domain.searchableDocumentsCount, 11); + }); }); suite('configuration operations', function() { -------------- next part -------------- HTML����������������������������... 다운로드