diff options
author | Kore Nordmann <github@kore-nordmann.de> | 2007-05-10 07:20:12 +0000 |
---|---|---|
committer | Kore Nordmann <github@kore-nordmann.de> | 2007-05-10 07:20:12 +0000 |
commit | f01b8b1bdfb55dd7e77c8b9eec8def3989a6560c (patch) | |
tree | 15c30d4ff7dbd2ce210d0a292e50d8c2f4089a3e | |
parent | e7c4e0a2f06c711ed70923ef62f8c417f442766b (diff) | |
download | zetacomponents-graph-f01b8b1bdfb55dd7e77c8b9eec8def3989a6560c.zip zetacomponents-graph-f01b8b1bdfb55dd7e77c8b9eec8def3989a6560c.tar.gz |
- Fixed element option tests to test the right property
# Blame copy & paste
-rw-r--r-- | tests/element_options_test.php | 35 |
1 files changed, 32 insertions, 3 deletions
diff --git a/tests/element_options_test.php b/tests/element_options_test.php index 81332a6..6687714 100644 --- a/tests/element_options_test.php +++ b/tests/element_options_test.php @@ -415,6 +415,35 @@ class ezcGraphElementOptionsTest extends ezcTestImageCase $this->fail( 'Expected ezcBaseValueException.' ); } + public function testChartElementLegendPropertyPadding() + { + $options = new ezcGraphChartElementLegend(); + + $this->assertSame( + 0, + $options->padding, + 'Wrong default value for property padding in class ezcGraphChartElementLegend' + ); + + $options->padding = 1; + $this->assertSame( + 1, + $options->padding, + 'Setting property value did not work for property padding in class ezcGraphChartElementLegend' + ); + + try + { + $options->padding = false; + } + catch ( ezcBaseValueException $e ) + { + return true; + } + + $this->fail( 'Expected ezcBaseValueException.' ); + } + public function testChartElementLegendPropertyPortraitSize() { $options = new ezcGraphChartElementLegend(); @@ -492,7 +521,7 @@ class ezcGraphElementOptionsTest extends ezcTestImageCase try { - $options->landscapeSize = false; + $options->symbolSize = false; } catch ( ezcBaseValueException $e ) { @@ -521,7 +550,7 @@ class ezcGraphElementOptionsTest extends ezcTestImageCase try { - $options->landscapeSize = 42; + $options->minimumSymbolSize = 42; } catch ( ezcBaseValueException $e ) { @@ -550,7 +579,7 @@ class ezcGraphElementOptionsTest extends ezcTestImageCase try { - $options->landscapeSize = false; + $options->spacing = false; } catch ( ezcBaseValueException $e ) { |