Sha256: 9bc763686007aa110cd4121327f5914c2056e00af30fda57bde0842584c90881
Contents?: true
Size: 1.07 KB
Versions: 20
Compression:
Stored size: 1.07 KB
Contents
require 'spec_helper' describe Daengine::DigitalAssetProcessor do before { Daengine.configure(:assets_path => Dir.pwd+'/spec/mock_data', :daengine_yml_file => Dir.pwd+'/spec/mock_data/daengine.yml' ) } context "process_tuple_directory" do it 'processes only files modified in the last 2 days' do # process bulk deploy file in the mock dir DigitalAsset.destroy_all before = DigitalAsset.count FileUtils.touch Dir.pwd+'/spec/mock_data/bulk-ssc_deploy.xml' before = DigitalAsset.count Daengine::DigitalAssetProcessor.process_tuple_directory after = DigitalAsset.count (after - before).should > 1500 end it 'processes only those files that modified since the last time the daengine process ran' do # process any files that has modified since last run. None !! before = DigitalAsset.count Daengine::DigitalAssetProcessor.process_tuple_directory after = DigitalAsset.count (after - before).should == 0 end end end
Version data entries
20 entries across 20 versions & 1 rubygems