<commit_before>from canvas_object import CanvasObject

class Quiz(CanvasObject):


    def __str__(self):
        return "id %s, title: %s" % (
            self.id,
            self.title
        )


<commit_msg>Finished edit quiz and started delete quiz<commit_after>from canvas_object import CanvasObject
from util import combine_kwargs

class Quiz(CanvasObject):


    def __str__(self):
        return "id %s, title: %s" % (
            self.id,
            self.title
        )

    def edit_quiz(self, course_id, **kwargs):
        """
        Modifies an existing quiz
        :calls: `PUT /api/v1/courses/:course_id/quizzes/:id`
        <https://canvas.instructure.com/doc/api/quizzes.html#method.quizzes/quizzes_api.update>
        :rtype: Quiz
        """
        from course import Course
        response = self._requester.request(
            'PUT',
            'courses/%s/quizzes/%s' % (course_id, self.id),
            **combine_kwargs(**kwargs)
        )
        return Quiz(self._requester, response.json())

    def delete_quiz(self):
        """
        Deletes a quiz
        :calls: `DELETE /api/v1/courses/:course_id/quizzes/:id`
        <https://canvas.instructure.com/doc/api/quizzes.html#method.quizzes/quizzes_api.destroy>
        """
        from courses import Course
        response = self._requester.request(
            'DELETE',
            'courses/%s/'
        )

{'fraction_non_alphanumeric': 0.11937097927090778, 'fraction_numerical': 0.0014295925661186562, 'mean_word_length': 2.036876355748373, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1603431', 'n_tokens_mistral': 446, 'n_tokens_neox': 438, 'n_words': 85}