'Test the white_value if only a command topic is present.'

def test_show_white_value_if_only_command_topic(self):

    config = {light.DOMAIN: {'platform': 'mqtt', 'name': 'test', 'white_value_command_topic': 'test_light_rgb/white_value/set', 'command_topic': 'test_light_rgb/set', 'state_topic': 'test_light_rgb/status'}}
    with assert_setup_component(1, light.DOMAIN):
        assert setup_component(self.hass, light.DOMAIN, config)
    state = self.hass.states.get('light.test')
    self.assertEqual(STATE_OFF, state.state)
    self.assertIsNone(state.attributes.get('white_value'))
    fire_mqtt_message(self.hass, 'test_light_rgb/status', 'ON')
    self.hass.block_till_done()
    state = self.hass.states.get('light.test')
    self.assertEqual(STATE_ON, state.state)
    self.assertEqual(255, state.attributes.get('white_value'))
