summaryrefslogtreecommitdiffstats
path: root/tests/palette_test.php
diff options
context:
space:
mode:
authorKore Nordmann <github@kore-nordmann.de>2006-06-06 14:48:52 +0000
committerKore Nordmann <github@kore-nordmann.de>2006-06-06 14:48:52 +0000
commit2643696538c5546f3d271829e07734883e134c3c (patch)
tree87b45e93a62affaf4736acfb8a420472db1ebe5b /tests/palette_test.php
parent51bbe683d53acf187ebaca6af0e8dcf8dc2db6e7 (diff)
downloadzetacomponents-graph-2643696538c5546f3d271829e07734883e134c3c.zip
zetacomponents-graph-2643696538c5546f3d271829e07734883e134c3c.tar.gz
- Added gridColor option to palettes
- Differentiate between elements and charts background color
Diffstat (limited to 'tests/palette_test.php')
-rw-r--r--tests/palette_test.php22
1 files changed, 20 insertions, 2 deletions
diff --git a/tests/palette_test.php b/tests/palette_test.php
index 44d255b..86838fd 100644
--- a/tests/palette_test.php
+++ b/tests/palette_test.php
@@ -105,7 +105,7 @@ class ezcGraphPaletteTest extends ezcTestCase
$this->fail( 'Expected ezcGraphUnknownPaletteException.' );
}
- public function testBackgroundColor()
+ public function testChartBackgroundColor()
{
try
{
@@ -118,7 +118,25 @@ class ezcGraphPaletteTest extends ezcTestCase
$this->assertEquals(
ezcGraphColor::fromHex( '#EEEEEC' ),
- $chart->palette->background,
+ $chart->palette->chartBackground,
+ 'Background color not properly set.'
+ );
+ }
+
+ public function testElementBackgroundColor()
+ {
+ try
+ {
+ $chart = ezcGraph::create( 'Line' );
+ }
+ catch ( Exception $e )
+ {
+ $this->fail( $e->getMessage() );
+ }
+
+ $this->assertEquals(
+ ezcGraphColor::fromHex( '#000000FF' ),
+ $chart->palette->elementBackground,
'Background color not properly set.'
);
}
OpenPOWER on IntegriCloud