Files
codeql/python/extractor/cli-integration-test/string-encoding/test.sh
Taus d01593e571 Python: Add test for string encoding dataset check
Note that this test checks that the current setup creates dataset check
violations. A later commit will fix this (and flip the negation in the
test).
2024-10-21 12:08:46 +00:00

20 lines
486 B
Bash
Executable File

#!/bin/bash
set -Eeuo pipefail # see https://vaneyckt.io/posts/safer_bash_scripts_with_set_euxo_pipefail/
set -x
CODEQL=${CODEQL:-codeql}
SCRIPTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
cd "$SCRIPTDIR"
rm -rf db
$CODEQL database create db --language python --source-root repo_dir/
# Note the negation in front -- it witnesses the fact that currently the dataset check FAILS.
! $CODEQL dataset check db/db-python
echo "Test successfully completed."