spec/jldrill/stories/UserLoadsDictionary_story.rb in jldrill-0.5.1.7 vs spec/jldrill/stories/UserLoadsDictionary_story.rb in jldrill-0.6.0.1

- old
+ new

@@ -1,5 +1,6 @@ +# encoding: utf-8 require 'jldrill/spec/StoryMemento' require 'jldrill/spec/SampleQuiz' require 'jldrill/contexts/LoadReferenceContext' require 'jldrill/contexts/MainContext' require 'jldrill/views/test/FileProgress' @@ -126,14 +127,15 @@ it "should load the dictionary relative to the install directory" do Story.start options = Story.mainContext.quiz.options context = Story.context - Story.context.dictionaryName(options).should be(JLDrill::Config::DICTIONARY_NAME) - options.dictionary = "tempDictionary" - Story.context.dictionaryName(options).should eql("tempDictionary") + Story.context.dictionaryName(options).should be(JLDrill::Config::DICTIONARY_FILE) + testFile = File.join("tests","edict.utf") + options.dictionary = testFile + Story.context.dictionaryName(options).should eql(testFile) - Story.context.getFilename(options).should eql(File.join(JLDrill::Config::DICTIONARY_DIR, "tempDictionary")) + Story.context.getFilename(options).should eql(File.join(JLDrill::Config::DATA_DIR, testFile)) end end end