Skip to content

Commit

Permalink
Merge pull request #71 from pyranja/support-bundled-plugins
Browse files Browse the repository at this point in the history
Support bundled plugins in uploaded zip
  • Loading branch information
beomseoklee authored Jun 30, 2022
2 parents 0fffb8f + e9c5174 commit c30345c
Showing 1 changed file with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,22 @@ if [ "$TEST_TYPE" != "simple" ]; then
fi

sed -i -e "s|$TEST_ID.jmx|$JMETER_SCRIPT|g" test.json

# copy bundled plugin jars to jmeter extension folder to make them available to jmeter
BUNDLED_PLUGIN_DIR=`find $PWD -type d -name "plugins" | head -n 1`
# attempt to copy only if a /plugins folder is present in upload
if [ -z "$BUNDLED_PLUGIN_DIR" ]; then
echo "skipping plugin installation (no /plugins folder in upload)"
else
# ensure the jmeter extensions folder exists
JMETER_EXT_PATH=`find ~/.bzt/jmeter-taurus -type d -name "ext"`
if [ -z "$JMETER_EXT_PATH" ]; then
# fail fast - if plugins bundled they will be needed for the tests
echo "jmeter extension path (~/.bzt/jmeter-taurus/**/ext) not found - cannot install bundled plugins"
exit 1
fi
cp -v $BUNDLED_PLUGIN_DIR/*.jar $JMETER_EXT_PATH
fi
fi
fi

Expand Down

0 comments on commit c30345c

Please sign in to comment.