Sha256: feab22f7a4857ef893cf5d124dcb39007261df6960c76b71f7cad99dc6432621

Contents?: true

Size: 748 Bytes

Versions: 1

Compression:

Stored size: 748 Bytes

Contents

require 'jldrill/spec/StoryMemento'
require 'jldrill/spec/SampleQuiz'

# Sample quiz functionality.  Used as a mixin within a StoryMemento
module JLDrill::StoryFunctionality
    module SampleQuiz

        def hasDefaultQuiz
            @sampleQuiz = JLDrill::SampleQuiz.new
            @mainContext.quiz = @sampleQuiz.defaultQuiz
        end

        def sampleQuiz
            @sampleQuiz
        end

        def loadQuiz
            @sampleQuiz = JLDrill::SampleQuiz.new
            if @mainContext.quiz.loadFromString("SampleQuiz", 
                                                @sampleQuiz.resetFile)
                @mainContext.quiz.drill
            end
        end

        def quiz
            @mainContext.quiz
        end
    end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
jldrill-0.5.1.7 lib/jldrill/spec/storyFunctionality/SampleQuiz.rb