def setUp(self):
        "Variations on the constructors in the Elements notebook"

        key_dims1=[Dimension('Car occupants')]
        key_dims2=[Dimension('Cyclists')]
        value_dims1=['Count']
        self.bars1 = Bars([('one',8),('two', 10), ('three', 16)],
                          kdims=key_dims1, vdims=value_dims1)
        self.bars2 = Bars([('one',8),('two', 10), ('three', 17)],
                          kdims=key_dims1, vdims=value_dims1)
        self.bars3 = Bars([('one',8),('two', 10), ('three', 16)],
                          kdims=key_dims2, vdims=value_dims1)
Esempio n. 2
0
 def test_bars_string_signature(self):
     bars = Bars([], 'a', 'b')
     self.assertEqual(bars.kdims, [Dimension('a')])
     self.assertEqual(bars.vdims, [Dimension('b')])