diff --git a/.github/workflows/quality-gate.yml b/.github/workflows/quality-gate.yml index 028daff..cfb497b 100644 --- a/.github/workflows/quality-gate.yml +++ b/.github/workflows/quality-gate.yml @@ -63,7 +63,7 @@ jobs: run: | python -m pip install --upgrade pip pip install -r ${{ steps.prepare-requirements.outputs.PROCESSED_REQUIREMENTS_FILE }} - pip install pytest pytest-cov + pip install pytest pytest-cov pytest-asyncio - name: ⬇️ Setup Node.js 18 uses: actions/setup-node@v4 diff --git a/scouter/activities/faker.py b/scouter/activities/faker.py index c9fa119..deb89ad 100644 --- a/scouter/activities/faker.py +++ b/scouter/activities/faker.py @@ -44,7 +44,7 @@ class Faker(BaseActivity): """ topic = input_data.get('topic') num_messages = input_data.get( - 'num_messages', random.randint(1, len(self.tags))) + 'num_messages', random.randint(1, len(self.tags))) # NOSONAR if not topic: raise ValueError("Topic must be specified in input_data") @@ -54,11 +54,11 @@ class Faker(BaseActivity): for _ in range(num_messages): # Select random tag and name - tag = random.choice(list(self.tags.keys())) + tag = random.choice(list(self.tags.keys())) # NOSONAR name = self.tags[tag] # Generate random value between 0 and 100 - if random.random() < 0.1: + if random.random() < 0.1: # NOSONAR value = None else: value = round(random.uniform(0, 100), 2)