Skip to content

Commit

Permalink
Fix a bug where only 100 records can be added or deleted at a time by…
Browse files Browse the repository at this point in the history
… sending these batches and starting a new batch when crossing 100, 200, etc boundaries. Integration tests now pass.
  • Loading branch information
danielgtaylor committed Aug 21, 2013
1 parent e62a58b commit 4c81bea
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions tests/integration/route53/test_resourcerecordsets.py
Expand Up @@ -57,6 +57,11 @@ def test_record_count(self):
ip = '192.168.0.' + str(hostid)
created.add_value(ip)

# Max 100 changes per commit
if (hostid + 1) % 100 == 0:
rrs.commit()
rrs = ResourceRecordSets(self.conn, self.zone.id)

rrs.commit()

all_records = self.conn.get_all_rrsets(self.zone.id)
Expand All @@ -79,6 +84,11 @@ def test_record_count(self):
ip = '192.168.0.' + str(hostid)
deleted.add_value(ip)

# Max 100 changes per commit
if (hostid + 1) % 100 == 0:
rrs.commit()
rrs = ResourceRecordSets(self.conn, self.zone.id)

rrs.commit()

# 2nd count should match the number of hosts plus NS/SOA records
Expand Down

0 comments on commit 4c81bea

Please sign in to comment.