def test_memory(self):
        with patch.dict(sysbench.__salt__,
                        {'cmd.run': MagicMock(return_value={'A': 'a'})}):
            with patch.object(sysbench, '_parser', return_value={'A': 'a'}):
                self.assertEqual(sysbench.memory(),
                                 {'Operation: read Scope: local':
                                  {'A': 'a'},
                                  'Operation: write Scope: local':
                                  {'A': 'a'},
                                  'Operation: read Scope: global':
                                  {'A': 'a'},
                                  'Operation: write Scope: global':
                                  {'A': 'a'}})
Test to this tests the memory for read and write operations.
dataset/ETHPy150Open saltstack/salt/tests/unit/modules/sysbench_test.py/SysbenchTestCase.test_memory