Sha256: 608addd0a4535a4b32a0b19d0414737ad9141ac81f16ffb53a55839440dd1d81
Contents?: true
Size: 1.08 KB
Versions: 47
Compression:
Stored size: 1.08 KB
Contents
require 'rails_helper' require 'generators/bobot/install_generator' RSpec.describe Bobot::InstallGenerator, type: :generator do destination File.expand_path('../../dummy/tmp/generator', __FILE__) arguments ['bot'] before do prepare_destination end it 'mounts Bobot as Engine and generates Bobot Initializer' do expect_any_instance_of(generator_class).to receive(:route). with('mount Bobot::Engine => \'/bot\', as: \'bot\'') silence_stream(STDOUT) do generator.invoke('install') end expect(destination_root).to have_structure { directory 'config' do directory 'initializers' do file 'bobot.rb' do contains 'Bobot.configure' end end directory 'locales' do file 'bobot.en.yml' do contains 'en:' end file 'bobot.fr.yml' do contains 'fr:' end end end directory 'app' do directory 'bobot' do file 'workflow.rb' do contains 'Bobot::Commander' end end end } end end
Version data entries
47 entries across 47 versions & 1 rubygems