Guest User

Untitled

a guest
Feb 19th, 2018
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.90 KB | None | 0 0
  1. DOT_NET_PATH = "C:/Windows/Microsoft.NET/Framework/v3.5/"
  2. NUNIT_PATH = "tools//nunit-2.4.6//nunit-console.exe"
  3. PACKAGE_PATH = "build/package"
  4. SOLUTION = "src/XF.sln"
  5. CONFIG = "Debug"
  6.  
  7. task :default => ["build:all"]
  8.  
  9. namespace :build do
  10.  
  11. task :all => [:compile, :harvest, :test]
  12.  
  13. desc "Use MSBuild to build the solution: '#{SOLUTION}'"
  14. task :compile do
  15. sh "#{DOT_NET_PATH}msbuild.exe /p:Configuration=#{CONFIG} #{SOLUTION}"
  16. end
  17.  
  18. desc "Harvest build outputs to: '#{pwd}\\#{PACKAGE_PATH}'"
  19. task :harvest => [:compile] do
  20. require 'build/scripts/file_handling.rb'
  21. package_files
  22. end
  23.  
  24. desc "Executes class specifications (BDD)"
  25. task :test => [:harvest] do
  26. specs = Dir.glob(File.join("#{PACKAGE_PATH}", "*.Specs.dll")).join " "
  27. xml_file = File.join(PACKAGE_PATH, "nunit-test-report.xml")
  28. sh "#{NUNIT_PATH} #{specs} /nologo /xml=#{xml_file}"
  29. end
  30.  
  31. end
Add Comment
Please, Sign In to add comment