class Snowglobe::Configuration

Attributes

project_name[W]
root_directory[RW]
temporary_directory[RW]

Public Class Methods

new() click to toggle source
# File lib/snowglobe/configuration.rb, line 7
def initialize
  self.temporary_directory = Pathname.new("/tmp/snowglobe")
  @project_name = nil
  @database_name = nil
end

Public Instance Methods

database_name() click to toggle source
# File lib/snowglobe/configuration.rb, line 25
def database_name
  @database_name || project_name
end
project_name() click to toggle source
# File lib/snowglobe/configuration.rb, line 13
    def project_name
      if @project_name
        "#{@project_name}-test-app"
      else
        raise NotConfiguredError.new(<<~EXAMPLE)
          Snowglobe.configure do |config|
            config.project_name = "your_project_name"
          end
        EXAMPLE
      end
    end
update!() { |self| ... } click to toggle source
# File lib/snowglobe/configuration.rb, line 29
def update!
  yield self
end