]> git.r.bdr.sh - rbdr/lyricli.rb/blob - spec/lib/lyricli/source_manager_spec.rb
Adds -t / --title option to show header
[rbdr/lyricli.rb] / spec / lib / lyricli / source_manager_spec.rb
1 require "rspec"
2 require "lyricli"
3
4 describe Lyricli::SourceManager do
5 before :each do
6 # Stub the configuration
7 @example_configuration = {"enabled_sources" => "test_class"}
8 Configuration.stub(:'[]').and_return(@example_configuration)
9 Configuration.stub(:delete)
10
11 # Stub the test class.
12 module Lyricli
13 module Sources
14 module TestClass
15 end
16 end
17 end
18
19 @example_artist = {:artist => "The Shins", :song => "Know Your Onion"}
20
21 Lyricli::Sources::TestClass.stub(:enable)
22 Lyricli::Sources::TestClass.stub(:reset)
23 Lyricli::Sources::TestClass.stub(:current_track).and_return(@example_artist)
24 end
25 end