def test_save_request(self):
        request = HttpRequest()
        request.method = 'POST'
        request.POST['weightInput'] = '50'

        response = editorWeight(request)
        self.assertIn('50', response.content.decode())

        expected_html = render_to_string('editorweight.html',
                                         {'new_weight': '50'})
        print(expected_html)
        self.assertEqual(response.content.decode(), expected_html)
    def test_save_request(self):
        request = HttpRequest()
        request.method = 'POST'
        request.POST['weightInput'] = '50'

        response = editorWeight(request)
        self.assertIn('50', response.content.decode())

        expected_html = render_to_string(
            'editorweight.html',
            {'new_weight': '50'}
        )
        print(expected_html)
        self.assertEqual(response.content.decode(), expected_html)
    def test_response_html(self):
        request = HttpRequest()
        response = editorWeight(request)

        expected_html = render_to_string('editorWeight.html')
        self.assertEqual(response.content.decode(), expected_html)
    def test_response_html(self):
        request = HttpRequest()
        response = editorWeight(request)

        expected_html = render_to_string('editorWeight.html')
        self.assertEqual(response.content.decode(), expected_html)