File tree Expand file tree Collapse file tree 1 file changed +5
-0
lines changed
Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change 1616# This test builds and deploys the two secure services
1717# to test that they interact properly together.
1818
19+ import datetime
1920import os
2021import subprocess
2122import time
@@ -117,7 +118,11 @@ def test_end_to_end(services):
117118 time .sleep (10 ) # Slight delay writing to stackdriver
118119 client = logging_v2 .LoggingServiceV2Client ()
119120 resource_names = [f"projects/{ project } " ]
121+ # We add timestamp for making the query faster.
122+ now = datetime .datetime .now (datetime .timezone .utc )
123+ filter_date = now - datetime .timedelta (minutes = 1 )
120124 filters = (
125+ f"timestamp>=\" { filter_date .isoformat ('T' )} \" "
121126 "resource.type=cloud_run_revision "
122127 "AND severity=NOTICE "
123128 f"AND resource.labels.service_name={ service_name } "
You can’t perform that action at this time.
0 commit comments