def METHOD_NAME(self):
    timestamp = int(unix_time_millis())
    messages = []
    for i in range(25):
        messages.append({"message": f"Message number {i}", "timestamp": timestamp})
        timestamp += 100
    self.conn.put_log_events(
        logGroupName=self.log_group_name,
        logStreamName=self.log_stream_name,
        logEvents=messages,
    )
    res = self.conn.filter_log_events(
        logGroupName=self.log_group_name,
        logStreamNames=[self.log_stream_name],
        limit=20,
    )
    events = res["events"]
    assert len(events) == 20
    assert res["nextToken"] == "dummy@stream@" + events[-1]["eventId"]
    res = self.conn.filter_log_events(
        logGroupName=self.log_group_name,
        logStreamNames=[self.log_stream_name],
        limit=20,
        nextToken=res["nextToken"],
    )
    events += res["events"]
    assert len(events) == 25
    assert "nextToken" not in res
    for original_message, resulting_event in zip(messages, events):
        assert resulting_event["eventId"] == str(resulting_event["eventId"])
        assert resulting_event["timestamp"] == original_message["timestamp"]
        assert resulting_event["message"] == original_message["message"]
    res = self.conn.filter_log_events(
        logGroupName=self.log_group_name,
        logStreamNames=[self.log_stream_name],
        limit=20,
        nextToken="wrong-group@stream@999",
    )
    assert len(res["events"]) == 0
    assert "nextToken" not in res