features/step_definitions/cross_compilation.rb in luislavena-rake-compiler-0.5.0 vs features/step_definitions/cross_compilation.rb in luislavena-rake-compiler-0.6.0
- old
+ new
@@ -11,21 +11,22 @@
compiler = compilers.find do |comp|
paths.find do |path|
File.exist? File.join(path, comp)
end
end
- raise "Cannot locate '#{compiler}' in the PATH." unless compiler
+ pending "Cannot locate suitable compiler in the PATH." unless compiler
end
Then /^binaries for platform '(.*)' get generated$/ do |platform|
- ext = case platform
- when /darwin/
- 'bundle'
- when /mingw|mswin|linux/
- 'so'
- else
- RbConfig::CONFIG['DLEXT']
- end
+ ext = binary_extension(platform)
ext_for_platform = Dir.glob("tmp/#{platform}/**/*.#{ext}")
+ ext_for_platform.should_not be_empty
+end
+
+Then /^binaries for platform '(.*)' version '(.*)' get copied$/ do |platform, version|
+ lib_path = "lib/#{version}"
+ ext = binary_extension(platform)
+
+ ext_for_platform = Dir.glob("#{lib_path}/*.#{ext}")
ext_for_platform.should_not be_empty
end