mdarby-pollster 0.1.2.2 → 0.1.2.3
Sign up to get free protection for your applications and to get access to all the features.
@@ -42,12 +42,6 @@ describe <%= class_name %> do
|
|
42
42
|
@<%= object_name %>.total_votes.should == 1
|
43
43
|
end
|
44
44
|
|
45
|
-
it "should know how to shave the options yak" do
|
46
|
-
@<%= object_name %>.options = [{"options" => "first"}, {"options" => "second"}, {"options" => "third"}]
|
47
|
-
@<%= object_name %>.save
|
48
|
-
@<%= object_name %>.options.should == ["first", "second", "third"]
|
49
|
-
end
|
50
|
-
|
51
45
|
it "should be visible for a week after its end date" do
|
52
46
|
Date.stub!(:today => Date.parse("2009-01-09"))
|
53
47
|
@<%= object_name %>.stub!(:ends_at => Date.parse("2009-01-07"))
|
@@ -1,7 +1,5 @@
|
|
1
|
-
<div
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
<br/>
|
6
|
-
<%% end %>
|
1
|
+
<div class="option">
|
2
|
+
<input name="<%= object_name %>[options][]" value="#{option}">
|
3
|
+
<%%= link_to_function "Remove", "$(this).up('.option').remove()" %>
|
4
|
+
<br/>
|
7
5
|
</div>
|