Sha256: c9134f11e279c93637cc140244c2ab7da8c824cc2691d0e5d80ce6a018c90165

Contents?: true

Size: 1.61 KB

Versions: 11

Compression:

Stored size: 1.61 KB

Contents

# This file was generated by the `rspec --init` command. Conventionally, all
# specs live under a `spec` directory, which RSpec adds to the `$LOAD_PATH`.
# Require this file using `require "spec_helper.rb"` to ensure that it is only
# loaded once.
#
# See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration

require 'xcodeproject/project'
require 'xcodeproject/exceptions'
require 'rr' 

RSpec.configure do |config|
	config.treat_symbols_as_metadata_keys_with_true_values = true
	config.run_all_when_everything_filtered = true
	config.filter_run :focus
  config.mock_with :rr
end

#	Example project file hierarhy
#
# main
# \--group1a
#    |--group2a
#    |--dir2c
#    |   \--dir3a
#    |      \--dir4a
#    |         |--file5a-a.m
#    |         |--file5a-a.h
#    |         |--file5a-r.m
#    |         \--file5a-r.h
#    |
#    |--file2c.m
#    \--file2c.h

def prepare_sandbox
	%x{ mkdir -p #{example_sandbox_path} } unless File.exist?(example_sandbox_path)
end

def prepare_example_project
	prepare_sandbox

	proj_source_dir = "#{File.dirname(__FILE__)}/../resources/example"
	%x{ rm -vr #{example_project_dir} }
	%x{ cp -vr #{proj_source_dir} #{example_sandbox_path} }

	XcodeProject::Project.new(example_project_bundle_path)
end

def example_sandbox_path;        Pathname.new('/tmp/example_sandbox') end
def example_empty_sandbox_path;  Pathname.new('/tmp/example_sandbox_empty') end
def example_project_dir;         example_sandbox_path.join('example') end
def example_project_bundle_path; example_project_dir.join('example.xcodeproj') end
def example_project_file_path;   example_project_bundle_path.join('project.pbxproj') end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
xcodeproject-0.3.13 spec/spec_helper.rb
xcodeproject-0.3.12 spec/spec_helper.rb
xcodeproject-0.3.11 spec/spec_helper.rb
xcodeproject-0.3.10 spec/spec_helper.rb
xcodeproject-0.3.9 spec/spec_helper.rb
xcodeproject-0.3.8 spec/spec_helper.rb
xcodeproject-0.3.6 spec/spec_helper.rb
xcodeproject-0.3.5 spec/spec_helper.rb
xcodeproject-0.3.1 spec/spec_helper.rb
xcodeproject-0.3.0 spec/spec_helper.rb
xcodeproject-0.2.4 spec/spec_helper.rb