Commit graph

478 commits

Author SHA1 Message Date
Katrina Owen
d6ed7d9722 Add heavy-handed tests against pie chart bug 2013-03-17 19:20:48 -06:00
Dan Rice
dc311221f1 Render notes using RedCloth without formatize
Removes the outdated bluecloth dependency
2013-03-13 17:03:58 +02:00
Matt Rogers
053e3fc8d6 Guard against the case days stale can be negative 2013-03-10 22:48:27 -05:00
Matt Rogers
c1c81d7653 Remove some of the time objects we no longer need 2013-03-10 13:55:21 -05:00
Matt Rogers
809154332f Remove the fake preferences object
It's no longer needed since we're not using the preferences in this
object anymore.
2013-03-10 13:47:26 -05:00
Matt Rogers
43275e064e Refactor the calculation for staleness
Provide the number of days that the todo was stale instead of a class
name to use in the view.

We'll use the number of days stale in the helper to determine the class
name
2013-03-10 13:46:22 -05:00
Matt Rogers
8ffe3cacca Move the fakes so that they're namespaced by the test
Prevents errors since the names clash with names used in other tests.
2013-03-09 22:38:38 -06:00
Matt Rogers
ccf5323588 Encapsulate the concept of staleness into its own class
Extract it from a single helper method and wrap it in a method object.
This lets us add tests around it and then (later) split the domain
concerns from the view concerns.
2013-03-09 22:38:38 -06:00
Katrina Owen
0b3a0b58a8 Refer to view values correctly in test 2013-03-05 07:48:08 -07:00
Matt Rogers
66827d0640 add test coverage for when we don't have any users
It wasn't being covered in the functional test for this controller.
2013-03-03 13:56:24 -06:00
Matt Rogers
7c5028f227 add the mocha stubbing and mocking library 2013-03-03 13:56:18 -06:00
Katrina Owen
e56fa5740a Make test name reflect actual data 2013-03-02 16:20:57 -05:00
Katrina Owen
c4433a5ea9 Don't round in ttc.min_sec method
This fixes a bug where it would round 1.8 days up to
2 days, and still display the extra hours in addition.
2013-03-02 16:16:45 -05:00
Katrina Owen
03282638af Move calculation out of view 2013-03-02 16:16:45 -05:00
Katrina Owen
62336f94cd Move time to complete stats into separate class
This separates out the calculations from the queries so we can get
decent tests around them.
2013-03-02 16:16:45 -05:00
Reinier Balt
2719cb87c7 use state machine from controller and handle exception 2013-03-02 14:52:21 +01:00
Katrina Owen
3f496db4b4 Split up the font size calculation
The font size is a view concern, but the relative size belongs in the
model layer.
2013-03-02 07:14:52 -05:00
Matt Rogers
8b0f3e986a Merge branch 'tag-cloud' of https://github.com/kytrinyx/tracks 2013-03-01 16:49:53 -06:00
Katrina Owen
a13199cdda Add unit test for tag cloud 2013-03-01 16:03:35 -05:00
Katrina Owen
63fb7a589c Add test for tag cloud query 2013-03-01 13:26:59 -05:00
Reinier Balt
acab98d4c7 fix failing tests 2013-03-01 16:22:29 +01:00
Reinier Balt
a5031f2069 add test for better unit coverage of project 2013-03-01 16:22:29 +01:00
Reinier Balt
bf3a1e653a increate test coverage for user and project model 2013-03-01 16:22:29 +01:00
Reinier Balt
99eed9f638 add state machine to context including a closed state 2013-03-01 16:22:29 +01:00
Katrina Owen
ce9db80743 Correct typo in variable name 2013-02-28 20:34:46 -05:00
Reinier Balt
ef91dd0c64 another set of dynamic finder migrations. All non-cucumber tests pass 2013-02-27 11:50:49 +01:00
Reinier Balt
583664be36 remove some dynamic finders (they are deprecated for rails4) and add test for untested method of context.rb 2013-02-25 10:21:04 +01:00
Katrina Owen
0b733b6183 Override #to_s on Tag for simplified joining 2013-02-19 08:47:47 -07:00
Katrina Owen
95a4ed6e4a Add Tag#label method 2013-02-18 15:12:53 -07:00
Katrina Owen
f28ff70f77 Find tag by lowercase name in tag test
The sqlite3 database is case sensitive, so searching for 'UPPER' when
the tag name has been changed to 'upper' before saving it will result in
an empty tag.
2013-02-17 19:41:28 -07:00
Reinier Balt
7eccf79ab6 fix regressions and use timecop to fix time in tests. Thanks Dan and Hans! 2013-01-06 16:04:07 +01:00
Reinier Balt
08257b8da5 forgot to remove debug lines 2013-01-01 22:52:44 +01:00
Reinier Balt
bb91ea6e32 fix stats_controller tests when running them in the first week of a month
need to figure out how to set system date from tests so that the test
are not using data relative from the day you run the tests
2013-01-01 22:45:12 +01:00
Reinier Balt
c8d2db6fc3 these belong to last commit 2012-12-23 22:49:48 +01:00
Matt Rogers
066c378705 Add test coverage generation using simplecov 2012-12-22 22:56:30 -06:00
Dan Rice
c838272622 Fix redirect to home page after open signup
Fixes #1349
2012-11-29 16:27:28 -05:00
Matt Rogers
de33b85238 Update the fixture data to work with PostgreSQL 2012-08-28 08:39:52 -05:00
Reinier Balt
dd83040ea0 fix #1305 and #1309. Only check on show_from in the past when you change the show_from. This will not prevent a save of the todo when another change is made and show_from has some old date 2012-08-26 17:33:51 +02:00
Reinier Balt
1cdf6c8b8e fix #1325 by applying the patch of Dan Rice. Thanks Dan!
Also add a test to catch regessions
2012-08-25 17:18:22 +02:00
Reinier Balt
29c5103a98 handle multipart emails better in message_gateway 2012-08-24 23:47:27 +02:00
Matt Rogers
b01c7878d1 Push conversion of a todo to a project down.
Refactor the conversion of a todo to a project and move it from the
TodosController to the Project model.
2012-08-14 19:33:54 -05:00
Reinier Balt
a37d10f57a fix #1314. Fixed security issue too 2012-07-18 12:26:46 +02:00
Reinier Balt
881c83292b reorder tests 2012-07-18 11:59:17 +02:00
Reinier Balt
4e29bf69f7 fix failing tests and small refactorings 2012-07-18 11:42:26 +02:00
Reinier Balt
7c1cd2a144 fix #1310. Add test for this
Found that I had a lot of tests commented out. They have some regressions I will fix later
2012-07-15 21:28:42 +02:00
Reinier Balt
5a24644aad fix #1307 and add basic test 2012-07-15 20:45:37 +02:00
Reinier Balt
80e47b94b0 fix timezone issue
try testing at 00:30
2012-07-13 00:28:06 +02:00
Reinier Balt
e03c521314 fix regressions in cucumber tests. Add basis test for notes page 2012-07-12 23:33:36 +02:00
Reinier Balt
23b92d853a Merge pull request #84 from sukima/fix_projects_api_crash
Fix projects api crash
2012-07-11 06:36:51 -07:00
Devin Weaver
fefc0594c4 Removes unneeded comment
An erroneous commented line was inserted into
test/functional/projects_controller_test.rb
this patch removes it.
2012-07-09 08:00:41 -04:00