@ -115,7 +115,7 @@ TEST_F(VersionBuilderTest, ApplyAndSaveTo) {
VersionEdit version_edit ;
VersionEdit version_edit ;
version_edit . AddFile ( 2 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
version_edit . AddFile ( 2 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
GetInternalKey ( " 350 " ) , 200 , 200 ) ;
GetInternalKey ( " 350 " ) , 200 , 200 , false ) ;
version_edit . DeleteFile ( 3 , 27U ) ;
version_edit . DeleteFile ( 3 , 27U ) ;
EnvOptions env_options ;
EnvOptions env_options ;
@ -149,7 +149,7 @@ TEST_F(VersionBuilderTest, ApplyAndSaveToDynamic) {
VersionEdit version_edit ;
VersionEdit version_edit ;
version_edit . AddFile ( 3 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
version_edit . AddFile ( 3 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
GetInternalKey ( " 350 " ) , 200 , 200 ) ;
GetInternalKey ( " 350 " ) , 200 , 200 , false ) ;
version_edit . DeleteFile ( 0 , 1U ) ;
version_edit . DeleteFile ( 0 , 1U ) ;
version_edit . DeleteFile ( 0 , 88U ) ;
version_edit . DeleteFile ( 0 , 88U ) ;
@ -186,7 +186,7 @@ TEST_F(VersionBuilderTest, ApplyAndSaveToDynamic2) {
VersionEdit version_edit ;
VersionEdit version_edit ;
version_edit . AddFile ( 4 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
version_edit . AddFile ( 4 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
GetInternalKey ( " 350 " ) , 200 , 200 ) ;
GetInternalKey ( " 350 " ) , 200 , 200 , false ) ;
version_edit . DeleteFile ( 0 , 1U ) ;
version_edit . DeleteFile ( 0 , 1U ) ;
version_edit . DeleteFile ( 0 , 88U ) ;
version_edit . DeleteFile ( 0 , 88U ) ;
version_edit . DeleteFile ( 4 , 6U ) ;
version_edit . DeleteFile ( 4 , 6U ) ;
@ -214,15 +214,15 @@ TEST_F(VersionBuilderTest, ApplyMultipleAndSaveTo) {
VersionEdit version_edit ;
VersionEdit version_edit ;
version_edit . AddFile ( 2 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
version_edit . AddFile ( 2 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
GetInternalKey ( " 350 " ) , 200 , 200 ) ;
GetInternalKey ( " 350 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 676 , 0 , 100U , GetInternalKey ( " 401 " ) ,
version_edit . AddFile ( 2 , 676 , 0 , 100U , GetInternalKey ( " 401 " ) ,
GetInternalKey ( " 450 " ) , 200 , 200 ) ;
GetInternalKey ( " 450 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 636 , 0 , 100U , GetInternalKey ( " 601 " ) ,
version_edit . AddFile ( 2 , 636 , 0 , 100U , GetInternalKey ( " 601 " ) ,
GetInternalKey ( " 650 " ) , 200 , 200 ) ;
GetInternalKey ( " 650 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 616 , 0 , 100U , GetInternalKey ( " 501 " ) ,
version_edit . AddFile ( 2 , 616 , 0 , 100U , GetInternalKey ( " 501 " ) ,
GetInternalKey ( " 550 " ) , 200 , 200 ) ;
GetInternalKey ( " 550 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 606 , 0 , 100U , GetInternalKey ( " 701 " ) ,
version_edit . AddFile ( 2 , 606 , 0 , 100U , GetInternalKey ( " 701 " ) ,
GetInternalKey ( " 750 " ) , 200 , 200 ) ;
GetInternalKey ( " 750 " ) , 200 , 200 , false ) ;
EnvOptions env_options ;
EnvOptions env_options ;
@ -248,24 +248,24 @@ TEST_F(VersionBuilderTest, ApplyDeleteAndSaveTo) {
VersionEdit version_edit ;
VersionEdit version_edit ;
version_edit . AddFile ( 2 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
version_edit . AddFile ( 2 , 666 , 0 , 100U , GetInternalKey ( " 301 " ) ,
GetInternalKey ( " 350 " ) , 200 , 200 ) ;
GetInternalKey ( " 350 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 676 , 0 , 100U , GetInternalKey ( " 401 " ) ,
version_edit . AddFile ( 2 , 676 , 0 , 100U , GetInternalKey ( " 401 " ) ,
GetInternalKey ( " 450 " ) , 200 , 200 ) ;
GetInternalKey ( " 450 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 636 , 0 , 100U , GetInternalKey ( " 601 " ) ,
version_edit . AddFile ( 2 , 636 , 0 , 100U , GetInternalKey ( " 601 " ) ,
GetInternalKey ( " 650 " ) , 200 , 200 ) ;
GetInternalKey ( " 650 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 616 , 0 , 100U , GetInternalKey ( " 501 " ) ,
version_edit . AddFile ( 2 , 616 , 0 , 100U , GetInternalKey ( " 501 " ) ,
GetInternalKey ( " 550 " ) , 200 , 200 ) ;
GetInternalKey ( " 550 " ) , 200 , 200 , false ) ;
version_edit . AddFile ( 2 , 606 , 0 , 100U , GetInternalKey ( " 701 " ) ,
version_edit . AddFile ( 2 , 606 , 0 , 100U , GetInternalKey ( " 701 " ) ,
GetInternalKey ( " 750 " ) , 200 , 200 ) ;
GetInternalKey ( " 750 " ) , 200 , 200 , false ) ;
version_builder . Apply ( & version_edit ) ;
version_builder . Apply ( & version_edit ) ;
VersionEdit version_edit2 ;
VersionEdit version_edit2 ;
version_edit . AddFile ( 2 , 808 , 0 , 100U , GetInternalKey ( " 901 " ) ,
version_edit . AddFile ( 2 , 808 , 0 , 100U , GetInternalKey ( " 901 " ) ,
GetInternalKey ( " 950 " ) , 200 , 200 ) ;
GetInternalKey ( " 950 " ) , 200 , 200 , false ) ;
version_edit2 . DeleteFile ( 2 , 616 ) ;
version_edit2 . DeleteFile ( 2 , 616 ) ;
version_edit2 . DeleteFile ( 2 , 636 ) ;
version_edit2 . DeleteFile ( 2 , 636 ) ;
version_edit . AddFile ( 2 , 806 , 0 , 100U , GetInternalKey ( " 801 " ) ,
version_edit . AddFile ( 2 , 806 , 0 , 100U , GetInternalKey ( " 801 " ) ,
GetInternalKey ( " 850 " ) , 200 , 200 ) ;
GetInternalKey ( " 850 " ) , 200 , 200 , false ) ;
version_builder . Apply ( & version_edit2 ) ;
version_builder . Apply ( & version_edit2 ) ;
version_builder . SaveTo ( & new_vstorage ) ;
version_builder . SaveTo ( & new_vstorage ) ;