def on_start(self): num_users = int(flow_helper.get_env("NUM_USERS")) print(f"*** Production-like workload with {num_users} users ***") # Create a tracking dictionary to allow selection of previously logged # in users and restoration on specific cookies self.visited = VISITED # TODO - Make these tunable # Wait till this percentage of users have visited before enabling # random visited user selection. self.visited_min_pct = 1 # Target percentage of remembered users for regular sign_in self.remembered_target = REMEMBERED_PERCENT # Calculate minimum number based on passed users self.visited_min = int(0.01 * self.visited_min_pct * num_users)
def test_get_env(): os.environ["TESTKEY"] = "testvalue" assert get_env("TESTKEY") == "testvalue" with pytest.raises(Exception): get_env("UNSETKEY")
def on_start(self): print("*** Starting Sign-In failure load tests with " + flow_helper.get_env("NUM_USERS") + " users ***")