test/generators/model_generator_test.rb in ember-appkit-rails-0.2.2 vs test/generators/model_generator_test.rb in ember-appkit-rails-0.3.0

- old
+ new

@@ -13,16 +13,22 @@ run_generator ["post", "title:string"] assert_file "#{app_path}/models/post.js.es6" end test "create namespaced model" do - run_generator ["post/doineedthis", "title:string"] - assert_file "#{app_path}/models/post/doineedthis.js.es6" + run_generator ["post/dog", "title:string"] + assert_file "#{app_path}/models/post/dog.js.es6" end test "leave parentheses when create model w/o attributes" do run_generator ["post"] assert_file "#{app_path}/models/post.js.es6", /export default DS.Model.extend/ + end + + test "forces pluarl names to singular" do + run_generator ["posts"] + assert_file "#{app_path}/models/post.js.es6" + assert_no_file "#{app_path}/models/posts.js.es6" end test "Assert files are properly created" do run_generator %w(ember)