newgem 0.29.0 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (57) hide show
  1. data/History.txt +15 -1
  2. data/Manifest.txt +7 -22
  3. data/README.rdoc +55 -33
  4. data/Rakefile +22 -7
  5. data/app_generators/newgem/newgem_generator.rb +23 -23
  6. data/app_generators/newgem/templates/Rakefile +27 -3
  7. data/app_generators/newgem/templates/lib/module.rb +1 -1
  8. data/bin/newgem +12 -2
  9. data/config/website.yml +2 -0
  10. data/features/development.feature +22 -0
  11. data/features/executable_generator.feature +6 -6
  12. data/features/expected_outputs/newgem.out +2 -9
  13. data/features/install_cucumber.feature +11 -0
  14. data/features/install_website.feature +13 -0
  15. data/features/newgem_cli.feature +60 -0
  16. data/features/steps/cli.rb +125 -36
  17. data/features/steps/env.rb +4 -2
  18. data/lib/newgem/support/tasks.rb +10 -0
  19. data/lib/newgem/tasks.rb +1 -0
  20. data/lib/newgem.rb +5 -5
  21. data/newgem_generators/install_website/install_website_generator.rb +12 -9
  22. data/newgem_generators/install_website/templates/config/website.yml.sample.erb +2 -0
  23. data/newgem_generators/install_website/templates/script/txt2html +5 -16
  24. data/newgem_generators/install_website/templates/tasks/website.rake +34 -4
  25. data/rubygems_generators/executable/templates/test/test_cli.rb.erb +1 -1
  26. data/script/txt2html +5 -16
  27. data/tasks/deployment.rake +5 -6
  28. data/tasks/website.rake +34 -6
  29. data/test/test_install_website_generator.rb +1 -0
  30. data/test/test_newgem_generator.rb +0 -10
  31. data/website/index.html +27 -22
  32. data/website/index.txt +30 -19
  33. data/website/rubyforge.html +2 -2
  34. data/website/version.js +0 -4
  35. metadata +35 -67
  36. data/Todo.txt +0 -4
  37. data/app_generators/newgem/templates/config/hoe.rb +0 -82
  38. data/app_generators/newgem/templates/config/requirements.rb +0 -15
  39. data/app_generators/newgem/templates/lib/version.rb +0 -10
  40. data/app_generators/newgem/templates/setup.rb +0 -1585
  41. data/app_generators/newgem/templates/tasks/deployment.rake +0 -34
  42. data/app_generators/newgem/templates/tasks/environment.rake +0 -7
  43. data/app_generators/newgem/templates/tasks/website.rake +0 -9
  44. data/config/hoe.rb +0 -62
  45. data/features/cli.feature +0 -28
  46. data/features/steps/executable_generator.rb +0 -0
  47. data/lib/newgem/version.rb +0 -9
  48. data/rubygems_generators/install_rspec_stories/USAGE +0 -5
  49. data/rubygems_generators/install_rspec_stories/install_rspec_stories_generator.rb +0 -54
  50. data/rubygems_generators/install_rspec_stories/templates/all.rb +0 -8
  51. data/rubygems_generators/install_rspec_stories/templates/steps.rb +0 -13
  52. data/rubygems_generators/install_rspec_stories/templates/story.story +0 -9
  53. data/script/txt2html.rb +0 -70
  54. data/script/txt2js +0 -59
  55. data/setup.rb +0 -1585
  56. data/tasks/generator_report.rake +0 -19
  57. data/test/test_install_rspec_stories_generator.rb +0 -45
@@ -1,19 +0,0 @@
1
- desc 'Check that files included in generators match those in use by newgem itself'
2
- task :generator_report do
3
- files = [
4
- %w( script/generate app_generators/newgem ),
5
- %w( script/destroy app_generators/newgem ),
6
- %w( tasks/deployment.rake app_generators/newgem ),
7
- %w( tasks/environment.rake app_generators/newgem ),
8
- %w( test/test_generator_helper.rb rubygems_generators/component_generator ),
9
- %w( tasks/website.rake newgem_generators/website ),
10
- ]
11
- # add "templates/#{source}" to each 2nd string
12
- end
13
-
14
- # def identical?(source, destination, &block)
15
- # return false if File.directory? destination
16
- # source = block_given? ? File.open(source) {|sf| yield(sf)} : IO.read(source)
17
- # destination = IO.read(destination)
18
- # source == destination
19
- # end
@@ -1,45 +0,0 @@
1
- require File.join(File.dirname(__FILE__), "test_generator_helper.rb")
2
-
3
- class TestInstallRspecStoriesGenerator < Test::Unit::TestCase
4
- include RubiGen::GeneratorTestHelper
5
-
6
- def setup
7
- bare_setup
8
- end
9
-
10
- def teardown
11
- bare_teardown
12
- end
13
-
14
- # Some generator-related assertions:
15
- # assert_generated_file(name, &block) # block passed the file contents
16
- # assert_directory_exists(name)
17
- # assert_generated_class(name, &block)
18
- # assert_generated_module(name, &block)
19
- # assert_generated_test_for(name, &block)
20
- # The assert_generated_(class|module|test_for) &block is passed the body of the class/module within the file
21
- # assert_has_method(body, *methods) # check that the body has a list of methods (methods with parentheses not supported yet)
22
- #
23
- # Other helper methods are:
24
- # app_root_files - put this in teardown to show files generated by the test method (e.g. p app_root_files)
25
- # bare_setup - place this in setup method to create the APP_ROOT folder for each test
26
- # bare_teardown - place this in teardown method to destroy the TMP_ROOT or APP_ROOT folder after each test
27
-
28
- def test_generator_without_options
29
- run_generator('install_rspec_stories', [], sources)
30
- assert_directory_exists("stories/steps")
31
- assert_generated_file("stories/steps/myproject_steps.rb")
32
- assert_generated_file("stories/sell_myproject.story")
33
- assert_generated_file("stories/all.rb")
34
- end
35
-
36
- private
37
- def sources
38
- [RubiGen::PathSource.new(:test, File.join(File.dirname(__FILE__),"..", generator_path))
39
- ]
40
- end
41
-
42
- def generator_path
43
- "rubygems_generators"
44
- end
45
- end