s3_rotate 1.1.0 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
 - data/lib/s3_rotate/aws/s3_client.rb +21 -6
 - data/s3_rotate.gemspec +1 -1
 - data/spec/s3_rotate/aws/s3_client_spec.rb +22 -22
 - data/spec/s3_rotate/core/backup_rotator_spec.rb +474 -474
 - data/spec/s3_rotate/core/backup_uploader_spec.rb +6 -6
 - metadata +2 -2
 
| 
         @@ -27,12 +27,12 @@ describe S3Rotate::BackupUploader do 
     | 
|
| 
       27 
27 
     | 
    
         | 
| 
       28 
28 
     | 
    
         
             
                it 'uploads all the new files until reaching an already uploaded file' do
         
     | 
| 
       29 
29 
     | 
    
         
             
                  # mock
         
     | 
| 
       30 
     | 
    
         
            -
                  @client.connection.directories.get('bucket').files.create(key: ' 
     | 
| 
       31 
     | 
    
         
            -
                  @client.connection.directories.get('bucket').files.create(key: ' 
     | 
| 
       32 
     | 
    
         
            -
                  @client.connection.directories.get('bucket').files.create(key: ' 
     | 
| 
       33 
     | 
    
         
            -
                  @client.connection.directories.get('bucket').files.create(key: ' 
     | 
| 
       34 
     | 
    
         
            -
                  @client.connection.directories.get('bucket').files.create(key: ' 
     | 
| 
       35 
     | 
    
         
            -
                  @client.connection.directories.get('bucket').files.create(key: ' 
     | 
| 
      
 30 
     | 
    
         
            +
                  @client.connection.directories.get('bucket').files.create(key: 'backup_name/daily/2020-01-02.tgz', body: 'some data')
         
     | 
| 
      
 31 
     | 
    
         
            +
                  @client.connection.directories.get('bucket').files.create(key: 'backup_name/daily/2020-01-03.tgz', body: 'some data')
         
     | 
| 
      
 32 
     | 
    
         
            +
                  @client.connection.directories.get('bucket').files.create(key: 'backup_name/daily/2020-01-04.tgz', body: 'some data')
         
     | 
| 
      
 33 
     | 
    
         
            +
                  @client.connection.directories.get('bucket').files.create(key: 'backup_name/weekly/2020-01-05.tgz', body: 'some data')
         
     | 
| 
      
 34 
     | 
    
         
            +
                  @client.connection.directories.get('bucket').files.create(key: 'backup_name/monthly/2020-01-06.tgz', body: 'some data')
         
     | 
| 
      
 35 
     | 
    
         
            +
                  @client.connection.directories.get('bucket').files.create(key: 'other_backup_name/daily/2020-01-07.tgz', body: 'some data')
         
     | 
| 
       36 
36 
     | 
    
         | 
| 
       37 
37 
     | 
    
         
             
                  allow(S3Rotate::FileUtils).to receive(:date_from_filename).and_call_original
         
     | 
| 
       38 
38 
     | 
    
         
             
                  allow(S3Rotate::FileUtils).to receive(:extension_from_filename).and_call_original
         
     | 
    
        metadata
    CHANGED
    
    | 
         @@ -1,14 +1,14 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            --- !ruby/object:Gem::Specification
         
     | 
| 
       2 
2 
     | 
    
         
             
            name: s3_rotate
         
     | 
| 
       3 
3 
     | 
    
         
             
            version: !ruby/object:Gem::Version
         
     | 
| 
       4 
     | 
    
         
            -
              version: 1. 
     | 
| 
      
 4 
     | 
    
         
            +
              version: 1.2.0
         
     | 
| 
       5 
5 
     | 
    
         
             
            platform: ruby
         
     | 
| 
       6 
6 
     | 
    
         
             
            authors:
         
     | 
| 
       7 
7 
     | 
    
         
             
            - Simon Ninon
         
     | 
| 
       8 
8 
     | 
    
         
             
            autorequire: 
         
     | 
| 
       9 
9 
     | 
    
         
             
            bindir: bin
         
     | 
| 
       10 
10 
     | 
    
         
             
            cert_chain: []
         
     | 
| 
       11 
     | 
    
         
            -
            date: 2020-02- 
     | 
| 
      
 11 
     | 
    
         
            +
            date: 2020-02-29 00:00:00.000000000 Z
         
     | 
| 
       12 
12 
     | 
    
         
             
            dependencies:
         
     | 
| 
       13 
13 
     | 
    
         
             
            - !ruby/object:Gem::Dependency
         
     | 
| 
       14 
14 
     | 
    
         
             
              name: fog-aws
         
     |