Skip to content

Commit

Permalink
Update rapidpro python client to 2.16.0
Browse files Browse the repository at this point in the history
  • Loading branch information
norkans7 committed Dec 3, 2024
1 parent e9e5391 commit d3f3954
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 34 deletions.
8 changes: 4 additions & 4 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ mock = "^2.0.0"
pycountry = "^18.5.26"
django-countries = "^7.2.1"
regex = "^2023.8.8"
rapidpro-python = "^2.15.0"
rapidpro-python = "^2.16.0"
feedparser = "^6.0.2"
Markdown = "^2.6.11"
iso8601 = "^0.1.12"
Expand Down
36 changes: 7 additions & 29 deletions ureport/backend/tests/test_rapidpro.py
Original file line number Diff line number Diff line change
Expand Up @@ -1306,9 +1306,7 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
contact=ObjectRef.create(uuid="C-001", name="Wiz Kid"),
responded=True,
values={
"win": TembaRun.Value.create(
value="We'll win today", input="We'll win today", category="Win", node="ruleset-uuid", time=now
)
"win": TembaRun.Value.create(value="We'll win today", category="Win", node="ruleset-uuid", time=now)
},
path=[TembaRun.Step.create(node="ruleset-uuid", time=now)],
created_on=now,
Expand Down Expand Up @@ -1352,11 +1350,7 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
flow=ObjectRef.create(uuid="flow-uuid", name="Flow 1"),
contact=ObjectRef.create(uuid="C-002", name="Davido"),
responded=True,
values={
"sing": TembaRun.Value.create(
value="I sing", input="I sing", category="Sing", node="ruleset-uuid", time=now
)
},
values={"sing": TembaRun.Value.create(value="I sing", category="Sing", node="ruleset-uuid", time=now)},
path=[TembaRun.Step.create(node="ruleset-uuid", time=now)],
created_on=now,
modified_on=now,
Expand All @@ -1372,7 +1366,6 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
values={
"play": TembaRun.Value.create(
value="I play basketball",
input="I play basketball",
category="Play",
node="ruleset-uuid",
time=now,
Expand Down Expand Up @@ -1416,7 +1409,6 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
values={
"party": TembaRun.Value.create(
value="We'll celebrate today",
input="We'll celebrate today",
category="Party",
node="ruleset-uuid",
time=now + timedelta(minutes=1),
Expand Down Expand Up @@ -1499,7 +1491,6 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
values={
"dance": TembaRun.Value.create(
value="We'll dance today",
input="We'll dance today",
category="Dance",
node="ruleset-uuid",
time=now,
Expand Down Expand Up @@ -1543,7 +1534,6 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
values={
"dance": TembaRun.Value.create(
value="We'll dance today",
input="We'll dance today",
category="Dance",
node="ruleset-uuid",
time=now,
Expand Down Expand Up @@ -1631,7 +1621,6 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
values={
"party": TembaRun.Value.create(
value=long_text,
input=long_text,
category="Party",
node="ruleset-uuid",
time=now + timedelta(minutes=1),
Expand Down Expand Up @@ -1666,7 +1655,7 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
responded=True,
values={
"party": TembaRun.Value.create(
value=None, input="Party", category="Party", node="ruleset-uuid", time=now + timedelta(minutes=1)
value=None, category="Party", node="ruleset-uuid", time=now + timedelta(minutes=1)
)
},
path=[TembaRun.Step.create(node="ruleset-uuid", time=now)],
Expand Down Expand Up @@ -1700,9 +1689,7 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
contact=ObjectRef.create(uuid="C-001", name="Wiz Kid"),
responded=True,
values={
"dance": TembaRun.Value.create(
value="Whatever", input=None, category="No Response", node="ruleset-uuid", time=now
)
"dance": TembaRun.Value.create(value="Whatever", category="No Response", node="ruleset-uuid", time=now)
},
path=[
TembaRun.Step.create(node="ruleset-uuid", time=now),
Expand Down Expand Up @@ -1763,9 +1750,7 @@ def test_pull_results(self, mock_cache_get, mock_timezone_now, mock_get_runs, mo
contact=ObjectRef.create(uuid="C-001", name="Wiz Kid"),
responded=True,
values={
"win": TembaRun.Value.create(
value="We'll win today", input="We'll win today", category="Win", node="ruleset-uuid", time=now
)
"win": TembaRun.Value.create(value="We'll win today", category="Win", node="ruleset-uuid", time=now)
},
path=[
TembaRun.Step.create(node="ruleset-uuid", time=now),
Expand Down Expand Up @@ -1844,9 +1829,7 @@ def gzipped_records(records):
contact=ObjectRef.create(uuid="C-001", name="Wiz Kid"),
responded=True,
values={
"win": TembaRun.Value.create(
value="We'll win today", input="We'll win today", category="Win", node="ruleset-uuid", time=now
)
"win": TembaRun.Value.create(value="We'll win today", category="Win", node="ruleset-uuid", time=now)
},
path=[TembaRun.Step.create(node="ruleset-uuid", time=now)],
created_on=now,
Expand Down Expand Up @@ -1906,11 +1889,7 @@ def gzipped_records(records):
flow=ObjectRef.create(uuid="flow-uuid", name="Flow 1"),
contact=ObjectRef.create(uuid="C-002", name="Davido"),
responded=True,
values={
"sing": TembaRun.Value.create(
value="I sing", input="I sing", category="Sing", node="ruleset-uuid", time=now
)
},
values={"sing": TembaRun.Value.create(value="I sing", category="Sing", node="ruleset-uuid", time=now)},
path=[TembaRun.Step.create(node="ruleset-uuid", time=now)],
created_on=now,
modified_on=now,
Expand All @@ -1926,7 +1905,6 @@ def gzipped_records(records):
values={
"play": TembaRun.Value.create(
value="I play basketball",
input="I play basketball",
category="Play",
node="ruleset-uuid",
time=now,
Expand Down

0 comments on commit d3f3954

Please sign in to comment.