Sha256: 5623768b1d61b5f98e46ba17772d446e667cb9a96f76a931d65f583a718ea928
Contents?: true
Size: 1.01 KB
Versions: 2
Compression:
Stored size: 1.01 KB
Contents
require 'rmagick' require 'fileutils' require 'yaml' require 'pry' require_relative "nakal/version" require_relative 'nakal/base_screen' require_relative 'nakal/android/screen' require_relative 'nakal/ios/screen' require_relative 'nakal/dsl' module Nakal class<<self attr_accessor :device_name, :directory, :platform, :image_location, :default_crop_params attr_accessor :diff_screens, :embed_screenshot, :timeout def configure yield self end def create_image_dir dir @image_location = "#{@directory}/#{@device_name}/#{dir}" FileUtils.mkdir_p @image_location unless File.directory?(@image_location) end def current_platform Object.const_get("Nakal::#{Nakal.platform.capitalize}") end end end Nakal.configure do |config| config.device_name = "default_device" config.directory = "baseline_images" config.default_crop_params = (YAML.load(File.open './config/nakal.yml') rescue {}) config.embed_screenshot = false config.diff_screens = [] config.timeout = 30 end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
nakal-0.0.7 | lib/nakal.rb |
nakal-0.0.6 | lib/nakal.rb |