def test_colors_xterm(self):
        string = '\x1b]4;20;rgb:ff/ff/ff\x1b' \
            '\x1b]4;25;rgbi:1.0/1.0/1.0\x1b'
        substrings = list(self.processor.split_string(string))
        desired = { 20 : (255, 255, 255),
                    25 : (255, 255, 255) }
        self.assertEquals(self.processor.color_map, desired)

        string = '\x1b[38;5;20m\x1b[48;5;25m'
        substrings = list(self.processor.split_string(string))
        self.assertEquals(self.processor.foreground_color, 20)
        self.assertEquals(self.processor.background_color, 25)
Handles request and optionally finalizes the output stream.
dataset/ETHPy150Open ipython/ipython-py3k/IPython/frontend/qt/console/tests/test_ansi_code_processor.py/TestAnsiCodeProcessor.test_colors_xterm--crossover with--dataset/ETHPy150Open GoogleCloudPlatform/appengine-mapreduce/python/test/mapreduce/handlers_test.py/MapperWorkerCallbackHandlerTest._handle_request