Commit Graph

209 Commits

Author SHA1 Message Date
Simon Brunel
eb14481d02 Fix legend tests and disable other failing tests 2016-04-27 19:58:36 +02:00
Simon Brunel
a93b3f45ac Fix helpers, layoutService and logarithmic tests 2016-04-26 22:44:53 +02:00
Simon Brunel
e0353dac98 Fix bar, bubble, doughnut, and polarArea tests
Also replace the 2 spaces indentation in controller.bar.tests.js by tabs to match the overall code style.
2016-04-26 12:46:34 +02:00
Simon Brunel
8b156bdc98 New toBeCloseToPixel jasmine matcher
Because of differences between testing platforms, introduce a new matcher for (floating) pixel values comparison (currently 2 pixels tolerance).
2016-04-26 12:46:33 +02:00
Simon Brunel
886956441e New test helpers to acquire and release charts
Since we changed the way how meta data are stores, now unit tests need to work on real Chart instances. This commit brings some helpers to inject/cleanup HTML canvas and it's wrapper into/from the DOM.
2016-04-26 12:46:31 +02:00
Tanner Linsley
da90e2f670 Time scale now compensates for rounded tick units
Closes #2277
2016-04-25 17:48:21 -05:00
Evert Timberg
f613ad5c0f Comment out tests since they seem like a moment issue 2016-04-23 20:08:00 -04:00
Evert Timberg
b4a06f6e34 Merge branch 'master' into feature/pan-support
Conflicts:
	src/core/core.controller.js
2016-04-23 20:06:18 -04:00
Evert Timberg
c31c90b2e4 Backwards pixel to value API 2016-04-23 13:27:10 -04:00
Jannis Achstetter
75676019a1 Add testcases for the consistent dataset-specific option names "pointRadius" and "pointHitRadius" 2016-04-21 15:39:19 +02:00
Evert Timberg
bc90aaa522 Start on pan support 2016-04-21 07:48:47 -04:00
Jannis Achstetter
add9f8c3a4 Add a testcase for the new option name "lineTension" 2016-04-21 09:41:27 +02:00
Jannis Achstetter
b0c1e9cb69 "tension" is a property of the line, not of the point 2016-04-21 09:17:51 +02:00
Jannis Achstetter
6fcec4273e Fix test/defaultConfig.tests.js after PR #2308 2016-04-20 16:02:05 +02:00
Evert Timberg
d131e7d07a Use apply instead of call so that the animation easing can be passed to the draw callbacks 2016-04-17 12:25:47 -04:00
Evert Timberg
16570b0c0c Plugin system + tests 2016-04-17 12:02:33 -04:00
Evert Timberg
7c7739c25f Merge pull request #2276 from nnnick/fix/2229
Improved sizing when grid lines are not display
2016-04-17 10:38:45 -04:00
Evert Timberg
1a49872ce4 More prework for zoom/pan 2016-04-17 10:33:38 -04:00
Evert Timberg
73b6198d24 Fix tests 2016-04-17 08:54:27 -04:00
Evert Timberg
ca461479a8 Update docs 2016-04-16 21:50:45 -04:00
Evert Timberg
fac92448ff Update tests for new config option 2016-04-16 21:49:08 -04:00
Evert Timberg
b50c281684 Merge pull request #2273 from mdehoog/doughnut-rotation
Added unit test for doughnut rotation/circumference, fix for rotation = 0
2016-04-16 19:21:58 -04:00
Michael de Hoog
241f085533 Fix for doughnut rotation = 0, added unit test for doughnut rotation/circumference properties 2016-04-17 09:16:42 +10:00
Tanner Linsley
4f60eecc01 Better default tick rotation and tick autoskip settings (#2258)
* Better default tick rotation and tick autoskip settings

* scale.time: Use ctx to measure label, and <= instead of < for unit fitting

* Test Changes

* Passing Tests with new defaults
2016-04-16 17:38:03 -05:00
Tom Duncalf
0c854dd40c Allow gradients to be used as colors without causing errors when e.g. calling the color helper to generate the defualt colour value for hover 2016-04-13 09:46:39 +01:00
Evert Timberg
d5fd737058 Merge pull request #2206 from nnnick/fix/constraint-width-percent
Allow percentages as the max-width/max-height of the container
2016-04-03 13:18:06 -04:00
Evert Timberg
9ee70d6d48 Category scale supports min / max 2016-04-02 23:05:48 -04:00
Evert Timberg
b6d7ceba1c Add initial implementation of constraint percentage width / height support. Added tests for dom sizing methods. 2016-04-01 23:11:01 -04:00
Evert Timberg
cefaef4707 Fix tests 2016-03-26 10:49:02 -04:00
etimberg
21a33f0e41 Better conversion to ticks to make it easier to use callbacks 2016-03-16 19:39:09 -04:00
Ivan Samoylenko
f5bb8e25d5 Fixed bar.controller tests 2016-03-13 19:10:49 +03:00
Ivan Samoylenko
81e1448836 Added 'borderSkipped' parameter to Rectangle. 2016-03-13 18:58:36 +03:00
Evert Timberg
a87ebe0841 Fix test for time zone difference 2016-03-05 23:16:25 -05:00
Evert Timberg
c3f765857e Fix some time rounding problems 2016-03-05 22:58:34 -05:00
Matthias Winkelmann
9410eaabbf fixed timezone bug in test 2016-03-02 16:51:48 +01:00
Matthias Winkelmann
fc46e25f23 fixed test and added a test for a custom date parser 2016-03-02 16:40:58 +01:00
Evert Timberg
8d5b3809f6 Fix global font settings 2016-02-28 13:41:17 -05:00
Evert Timberg
04e6926961 Fix bar chart and doughnut chart animations 2016-02-27 12:32:20 -05:00
Tanner Linsley
ee81d4a804 Reversible Legends
Legends can now be reversed with the `reversed: true` property.
2016-02-17 12:42:09 -07:00
Tanner Linsley
ac5be9bde2 Proper line and bar stacking order
Stacked line and bar charts now behave predictably with the first
dataset on the bottom stacked upwards.
2016-02-17 12:41:32 -07:00
Evert Timberg
309ab1f477 Disable autoskipper for time scales 2016-02-15 09:41:35 -05:00
Evert Timberg
37b3fb5d6c Legend tests + fix minor bug where padding was not taken into account when going down to the next line 2016-02-15 09:23:31 -05:00
Evert Timberg
e589734cbb Title block tests 2016-02-14 18:04:12 -05:00
Evert Timberg
61ca178e2b Write an almost equals function and use it in the linear scale. Added a test for this new function. 2016-02-06 09:38:44 -05:00
Evert Timberg
d16f4fc5ce Add default font options 2016-02-01 21:06:54 -05:00
Evert Timberg
0e8babf1d7 Fix stacked bar data limit calculation 2016-02-01 18:44:39 -05:00
Evert Timberg
f75116a91e Update millisecond default format. Removed unnecessary space at right edge of time scale. 2016-01-30 16:35:10 -05:00
Evert Timberg
bfd6f5f78e Radar controller tests 2016-01-27 18:00:32 -05:00
Evert Timberg
0890c809aa default config tests 2016-01-24 15:15:36 -05:00
Evert Timberg
d0a0d57fe2 Initial polar area tests 2016-01-24 13:29:13 -05:00
Evert Timberg
6aa2933ec5 Bubble controller tests 2016-01-24 10:59:19 -05:00
Evert Timberg
d0b67c603b Line and bar test updates 2016-01-24 10:58:30 -05:00
Evert Timberg
c312835eb1 Add some tests for scales. Cleaned up some minor bugs in the time scale. Wrote better helpers for helpers.min and helpers.max 2016-01-23 12:44:55 -05:00
Evert Timberg
2d4e2f9889 Properly begin path before drawing line at edge of scale 2016-01-18 21:35:35 -05:00
Evert Timberg
62988e9768 Merge pull request #1912 from mathiask88/pointStyleFix
Fixes the point size for rect and rectRot
2016-01-18 15:55:06 -05:00
Mathias Küsel
b282a01ab6 Fixes rect size 2016-01-18 20:04:31 +01:00
Evert Timberg
1de0435feb Fix reversed ticks on linear scale + update test 2016-01-17 20:37:43 -05:00
Mathias Küsel
655c1152eb Adds different point styles 2016-01-16 18:07:57 +01:00
Mathias Küsel
24e4a924c4 Add option to disable line drawing 2016-01-14 13:39:06 +01:00
Evert Timberg
5070059ac1 Add template option for point labels + test + doc update 2016-01-09 14:39:43 -05:00
Evert Timberg
46861c9f0b Update bar controller tests 2016-01-09 09:58:14 -05:00
Evert Timberg
d49b5b82c7 Add test for scale 2016-01-09 09:51:04 -05:00
etimberg
8dca052a16 Add suggestedMin, suggestedMax, min, and max options to radialLinear scale 2016-01-02 21:03:09 -05:00
Evert Timberg
824f5880fb Merge pull request #1837 from nnnick/fix/1766
Better fitting of scales
2015-12-29 10:16:46 -05:00
Evert Timberg
081cf7ba07 Fix tests 2015-12-29 09:24:09 -05:00
Evert Timberg
754268890b Alias the pixel for nicer drawing 2015-12-28 09:37:31 -05:00
Evert Timberg
f2899934db Draw line at edge of scales & update tests 2015-12-28 09:26:59 -05:00
Tanner Linsley
31721a353c Merge pull request #1829 from nnnick/fix/1716-1731
Better tooltip positioning
2015-12-23 10:22:34 -07:00
Evert Timberg
bbc6f5aa5f Fix broken test 2015-12-23 12:00:56 -05:00
Tore Lervik
0437968a4e Fixed broken tests 2015-12-21 23:47:38 +01:00
Evert Timberg
63b14dc2a9 Merge pull request #1810 from olyckne/fix/ticks_callback
Fix ticks callback and auto skip
2015-12-21 08:23:55 -05:00
Mattias Lyckne
dec4a5f57a Fix tests 2015-12-21 08:43:48 +01:00
Evert Timberg
5f4e8a4c13 Merge pull request #1794 from nnnick/update-scale-lifecycle
Update Scale Lifcycle
2015-12-19 14:29:49 -05:00
Evert Timberg
283f1d7387 Update check to new system + fix tests 2015-12-17 09:31:01 -05:00
Evert Timberg
c8d3831152 Split out data limits step of scales into it's own step. Wire up callbacks from the options to those in the scale life-cycle. Updated the docs accordingly 2015-12-17 09:21:04 -05:00
Evert Timberg
cddfba1676 Better test 2015-12-15 19:33:38 -05:00
Evert Timberg
274897fc24 Fix tests 2015-12-15 19:30:09 -05:00
Evert Timberg
6d490fbbbb Merge pull request #1779 from olyckne/adds_min_and_max_to_y_axes
Adds min and max setting to axes
2015-12-14 21:55:17 -05:00
Mattias Lyckne
968db4e783 Adds min and max setting to axes 2015-12-14 09:22:34 +01:00
Evert Timberg
139cbe1c64 All dataset controllers now inherit from a common base class Chart.DatasetController. This makes writing external controllers much easier 2015-12-13 14:35:40 -05:00
Evert Timberg
39e5daaca8 Better property picking. Added a helper function so we don't have to write a complicated ternary everywhere. Updated tests accordingly. 2015-12-12 08:52:06 -05:00
Evert Timberg
819f865723 Merge branch 'v2.0-dev' into v2.0-legend
Conflicts:
	src/controllers/controller.doughnut.js
2015-12-07 22:10:38 -05:00
Evert Timberg
28fc6841f3 Add tooltipFormat option to time scale options.
Fix bars when displayed on a time scale.
Updated sample files.
2015-12-05 19:33:33 -05:00
Evert Timberg
89da20354c Fix tests 2015-12-05 09:55:17 -05:00
Evert Timberg
38afefde25 Doughnut controller needs to obey chart area size 2015-12-04 19:22:48 -05:00
Evert Timberg
dcc06eb3bb Merge branch 'v2.0-dev' into v2.0-legend
Conflicts:
	src/core/core.scaleService.js
2015-12-03 21:21:10 -05:00
Evert Timberg
14c2cf56d1 Merge pull request #1728 from ashayas/bugfix/1722
Realized minRotation not needed, removed as an option and removed from tests
2015-12-02 07:30:55 -05:00
npsecoding
164671ffeb Realized minRotaion not needed, removed as an option and removed from tests 2015-12-01 22:29:19 -08:00
etimberg
f609452727 Allow the user to change the time label display formats 2015-11-30 20:42:48 -05:00
Evert Timberg
a90aac7b26 Change scale show properties to display and update tests 2015-11-24 19:18:15 -05:00
Evert Timberg
7b719e6432 Modify layout service to be able to place horizontal boxes as either full width or not full width. Currently the legend is the only full width box we have. Scales were modified so as not to be full width, however Core.Scale can handle boxes that are full width.
Updated unit tests to use correct 'boxes' property of chart instance. Tests did not require numerical updates!

Added a test to cover placing a full width box.
2015-11-21 10:51:32 -05:00
Evert Timberg
2a9b3e5221 Merge branch 'v2.0-dev' into v2.0-legend
Conflicts:
	src/core/core.controller.js
2015-11-21 09:23:33 -05:00
Evert Timberg
ead6247cd8 Make sure data is converted to a number in scales when determining min and max. Add tests for this condition to linear, radialLinear, and logarithmic scales. 2015-11-17 18:43:18 -05:00
Evert Timberg
e00f9d5790 Fix tests 2015-11-17 18:38:19 -05:00
Tanner Linsley
5a80b9e501 Merge pull request #1645 from nnnick/fix/null-callback
Hide lines for which the tick label callback returns null or undefined
2015-11-16 16:10:16 -07:00
Tanner Linsley
ae9db841f9 Merge pull request #1646 from nnnick/fix/1640
Can now replace entire chart data object on the fly
2015-11-16 16:10:01 -07:00
Tanner Linsley
937d866bd3 Merge pull request #1647 from nnnick/fix/1324
Fall back to line settings for points if necessary
2015-11-16 16:09:53 -07:00
Evert Timberg
0495e45ff7 Can now skip in all cases (start, mid, end) whether or not there is a look 2015-11-15 11:16:41 -05:00
Evert Timberg
9c78de10ba Fix line tests. Still need to add tests of the skip code. 2015-11-14 23:16:07 -05:00
Evert Timberg
37249e4375 Fix an incorrect test setup 2015-11-14 22:52:10 -05:00