From d51d7ed18162b104366ea402026ce55fb22b37c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C4=93teris=20Caune?= Date: Sat, 12 Dec 2015 17:03:34 +0200 Subject: [PATCH] Remove body field from Ping model. --- hc/api/migrations/0018_remove_ping_body.py | 18 ++++++++++++++++++ hc/api/models.py | 1 - hc/api/tests/test_email_webhook.py | 1 - 3 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 hc/api/migrations/0018_remove_ping_body.py diff --git a/hc/api/migrations/0018_remove_ping_body.py b/hc/api/migrations/0018_remove_ping_body.py new file mode 100644 index 00000000..14930b42 --- /dev/null +++ b/hc/api/migrations/0018_remove_ping_body.py @@ -0,0 +1,18 @@ +# -*- coding: utf-8 -*- +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('api', '0017_auto_20151117_1032'), + ] + + operations = [ + migrations.RemoveField( + model_name='ping', + name='body', + ), + ] diff --git a/hc/api/models.py b/hc/api/models.py index 63dd3911..d604870a 100644 --- a/hc/api/models.py +++ b/hc/api/models.py @@ -97,7 +97,6 @@ class Ping(models.Model): remote_addr = models.GenericIPAddressField(blank=True, null=True) method = models.CharField(max_length=10, blank=True) ua = models.CharField(max_length=200, blank=True) - body = models.TextField(blank=True) class Channel(models.Model): diff --git a/hc/api/tests/test_email_webhook.py b/hc/api/tests/test_email_webhook.py index 25cf5f7c..d5ada880 100644 --- a/hc/api/tests/test_email_webhook.py +++ b/hc/api/tests/test_email_webhook.py @@ -30,7 +30,6 @@ class EmailTestCase(TestCase): pings = list(Ping.objects.all()) assert pings[0].scheme == "email" - assert pings[0].body == "This is raw message" def test_it_rejects_get(self): r = self.client.get("/handle_email/")