def test_update_template_1(self): """@Test: Check if Template can be updated @Feature: Template - Update @Assert: Template is updated """ content = generate_string("alpha", 10) name = generate_string("alpha", 10) try: new_obj = make_template( { 'name': name, 'content': content, } ) except CLIFactoryError as e: self.fail(e) result = Template.info({'id': new_obj['id']}) self.assertEqual(result.return_code, 0) self.assertEqual(len(result.stderr), 0) self.assertEqual(new_obj['name'], result.stdout['name']) updated_name = generate_string("alpha", 10) Template.update({'id': new_obj['id'], 'name': updated_name}) result = Template.info({'id': new_obj['id']}) self.assertEqual(result.return_code, 0) self.assertEqual(len(result.stderr), 0) self.assertEqual(updated_name, result.stdout['name'])
def test_positive_update_name(self): """Check if Template can be updated @Feature: Template - Update @Assert: Template is updated """ template = make_template() updated_name = gen_string("alpha") Template.update({"id": template["id"], "name": updated_name}) template = Template.info({"id": template["id"]}) self.assertEqual(updated_name, template["name"])
def test_positive_update_name(): """Check if Template can be updated :id: 99bdab7b-1279-4349-a655-4294395ecbe1 :expectedresults: Template is updated :CaseImportance: Critical """ template = make_template() updated_name = gen_string('alpha') Template.update({'id': template['id'], 'name': updated_name}) template = Template.info({'id': template['id']}) assert updated_name == template['name']
def test_positive_update_name(self): """Check if Template can be updated @Feature: Template - Update @Assert: Template is updated """ template = make_template() updated_name = gen_string('alpha') Template.update({ 'id': template['id'], 'name': updated_name, }) template = Template.info({'id': template['id']}) self.assertEqual(updated_name, template['name'])
def test_positive_update_name(self): """Check if Template can be updated @id: 99bdab7b-1279-4349-a655-4294395ecbe1 @Assert: Template is updated """ template = make_template() updated_name = gen_string('alpha') Template.update({ 'id': template['id'], 'name': updated_name, }) template = Template.info({'id': template['id']}) self.assertEqual(updated_name, template['name'])
def test_positive_update_name(self): """Check if Template can be updated :id: 99bdab7b-1279-4349-a655-4294395ecbe1 :expectedresults: Template is updated :CaseImportance: Critical """ template = make_template() updated_name = gen_string('alpha') Template.update({ 'id': template['id'], 'name': updated_name, }) template = Template.info({'id': template['id']}) self.assertEqual(updated_name, template['name'])