YUKI Hiroshi
null+****@clear*****
Thu Nov 1 13:39:50 JST 2012
YUKI Hiroshi 2012-11-01 13:39:50 +0900 (Thu, 01 Nov 2012) New Revision: 37fb2fbe67369b0225f1403a4670b78cb2e582e9 https://github.com/groonga/gcs/commit/37fb2fbe67369b0225f1403a4670b78cb2e582e9 Log: Sort expected records for TABLE_PAT_KEY Modified files: test/batch-processor.test.js test/database-domain.test.js test/fixture/companies/data-deleted.grn test/fixture/companies/data.grn Modified: test/batch-processor.test.js (+8 -8) =================================================================== --- test/batch-processor.test.js 2012-11-01 13:33:07 +0900 (ad4e4be) +++ test/batch-processor.test.js 2012-11-01 13:39:50 +0900 (cb21abd) @@ -96,6 +96,13 @@ suite('batch/processor/Processor (instance methods)', function() { age: 1, email_address: 'info �� razil.jp', product: ['moritapo','groonga'] }, + { id: 'id10', + name: 'U.S. Robots and Mechanical Men', + description: '', + address: 'New York, United States', + age: 10, + email_address: '', + product: ['ndr114','spd13'] }, { id: 'id6', name: 'Omni Consumer Products', description: '', @@ -103,14 +110,7 @@ suite('batch/processor/Processor (instance methods)', function() { address: 'Detroit and Delta City, Michigan, United States', age: 6, email_address: '', - product: ['robocop'] }, - { id: 'id10', - name: 'U.S. Robots and Mechanical Men', - description: '', - address: 'New York, United States', - age: 10, - email_address: '', - product: ['ndr114','spd13'] } + product: ['robocop'] } ]; assertSuccess(result, 3, 0, dump); }); Modified: test/database-domain.test.js (+11 -8) =================================================================== --- test/database-domain.test.js 2012-11-01 13:33:07 +0900 (b83ba1f) +++ test/database-domain.test.js 2012-11-01 13:39:50 +0900 (c941151) @@ -702,19 +702,19 @@ suite('database', function() { email_address: 'info �� razil.jp', name: 'Brazil', product: 'groonga' }, + { id: 'id10', + address: 'New York, United States', + age: 10, + description: '', + email_address: '', + name: 'U.S. Robots and Mechanical Men', + product: 'ndr114' }, { id: 'id2', address: 'Sapporo, Hokkaido, Japan', age: 2, description: '', email_address: 'info �� enishi-tech.com', name: 'Enishi Tech Inc.', - product: 'groonga' }, - { id: 'id3', - address: 'Hongo, Tokyo, Japan', - age: 3, - description: '', - email_address: 'info �� clear-code.com', - name: 'ClearCode Inc.', product: 'groonga' } ]; assert.deepEqual(actualDump.slice(0, 3), expectedDump); @@ -751,7 +751,10 @@ suite('database', function() { name: 'Nergal Heavy Industries', product: 'nadesico' } ]; - assert.deepEqual(actualDump.slice(-2), expectedDump); + assert.deepEqual(actualDump.filter(function(record) { + return record.id == 'id10' || record.id == 'id11'; + }), + expectedDump); }); test('searchableDocumentsCount', function() { Modified: test/fixture/companies/data-deleted.grn (+2 -2) =================================================================== --- test/fixture/companies/data-deleted.grn 2012-11-01 13:33:07 +0900 (f322e7c) +++ test/fixture/companies/data-deleted.grn 2012-11-01 13:39:50 +0900 (a2ccd62) @@ -1,6 +1,7 @@ load --table companies_00000000000000000000000000 [ ["_key","address","age","description","email_address","name","product"], +["id10","New York, United States",10,"","","U.S. Robots and Mechanical Men","ndr114"], ["id2","Sapporo, Hokkaido, Japan",2,"","info �� enishi-tech.com","Enishi Tech Inc.","groonga"], ["id3","Hongo, Tokyo, Japan",3,"","info �� clear-code.com","ClearCode Inc.","groonga"], ["id4","Granada, Moon",4,"","","Anaheim Electronics","gundam"], @@ -8,6 +9,5 @@ load --table companies_00000000000000000000000000 ["id6","Detroit and Delta City, Michigan, United States",6,"","","Omni Consumer Products","robocop"], ["id7","West City",7,"","","Capsule Corporation","time machine"], ["id8","United States",8,"","","Stark Industries","iron man"], -["id9","Tokyo, Japan",9,"","","Umbrella Corporation","tyrant"], -["id10","New York, United States",10,"","","U.S. Robots and Mechanical Men","ndr114"] +["id9","Tokyo, Japan",9,"","","Umbrella Corporation","tyrant"] ] Modified: test/fixture/companies/data.grn (+2 -2) =================================================================== --- test/fixture/companies/data.grn 2012-11-01 13:33:07 +0900 (db92a18) +++ test/fixture/companies/data.grn 2012-11-01 13:39:50 +0900 (2ec6745) @@ -2,6 +2,7 @@ load --table companies_00000000000000000000000000 [ ["_key","address","age","description","email_address","name","product"], ["id1","Shibuya, Tokyo, Japan",1,"","info �� razil.jp","Brazil","groonga"], +["id10","New York, United States",10,"","","U.S. Robots and Mechanical Men","ndr114"], ["id2","Sapporo, Hokkaido, Japan",2,"","info �� enishi-tech.com","Enishi Tech Inc.","groonga"], ["id3","Hongo, Tokyo, Japan",3,"","info �� clear-code.com","ClearCode Inc.","groonga"], ["id4","Granada, Moon",4,"","","Anaheim Electronics","gundam"], @@ -9,6 +10,5 @@ load --table companies_00000000000000000000000000 ["id6","Detroit and Delta City, Michigan, United States",6,"","","Omni Consumer Products","robocop"], ["id7","West City",7,"","","Capsule Corporation","time machine"], ["id8","United States",8,"","","Stark Industries","iron man"], -["id9","Tokyo, Japan",9,"","","Umbrella Corporation","tyrant"], -["id10","New York, United States",10,"","","U.S. Robots and Mechanical Men","ndr114"] +["id9","Tokyo, Japan",9,"","","Umbrella Corporation","tyrant"] ] -------------- next part -------------- HTML����������������������������...Download