{
24 |
25 | }
26 |
--------------------------------------------------------------------------------
/step-core/src/main/java/step/security/SecurityManager.java:
--------------------------------------------------------------------------------
1 | package step.security;
2 |
3 | import java.util.Arrays;
4 |
5 | import step.expressions.ExpressionHandler;
6 |
7 | public class SecurityManager {
8 |
9 | public static void assertNotInExpressionHandler() {
10 | final StackTraceElement[] stackTrace = Thread.currentThread().getStackTrace();
11 | boolean inExpressionHandler = Arrays.asList(stackTrace).stream()
12 | .filter(e -> e.getClassName().equals(ExpressionHandler.class.getName())).count() > 0;
13 | if(inExpressionHandler) {
14 | throw new SecurityException("This method cannot be called within custom expressions");
15 | }
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/step-core/src/test/java/step/core/resolvers/ResolverTest.java:
--------------------------------------------------------------------------------
1 | package step.core.resolvers;
2 |
3 | import static org.junit.Assert.*;
4 |
5 | import org.junit.Test;
6 |
7 | public class ResolverTest {
8 |
9 | @Test
10 | public void test() {
11 | final Resolver resolver = new Resolver();
12 | String resolve = resolver.resolve("test");
13 | assertEquals("test", resolve);
14 | resolve = resolver.resolve(null);
15 | assertEquals(null, resolve);
16 | resolver.register(s -> "resolvedValue");
17 | resolve = resolver.resolve("test");
18 | assertEquals("resolvedValue", resolve);
19 | resolve = resolver.resolve(null);
20 | assertEquals("resolvedValue", resolve);
21 | }
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/step-core/src/test/resources/.gitignore:
--------------------------------------------------------------------------------
1 | /step-core-model-test.jar
2 |
--------------------------------------------------------------------------------
/step-core/src/test/resources/folder.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-core/src/test/resources/folder.zip
--------------------------------------------------------------------------------
/step-core/src/test/resources/step/resources/TestResource.txt:
--------------------------------------------------------------------------------
1 | TEST
--------------------------------------------------------------------------------
/step-core/src/test/resources/step/resources/TestResource2.txt:
--------------------------------------------------------------------------------
1 | TEST2
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-composite/step-functions-plugins-composite-def/src/main/java/step/plugins/functions/types/CompositeFunctionUtils.java:
--------------------------------------------------------------------------------
1 | package step.plugins.functions.types;
2 |
3 | import step.core.accessors.AbstractOrganizableObject;
4 | import step.core.plans.Plan;
5 | import step.handlers.javahandler.Keyword;
6 |
7 | import java.lang.reflect.Method;
8 | import java.util.HashMap;
9 |
10 | public class CompositeFunctionUtils {
11 | public static CompositeFunction createCompositeFunction(Keyword annotation, Method m, Plan plan) {
12 | CompositeFunction function = new CompositeFunction();
13 |
14 | String functionName = annotation.name().length() > 0 ? annotation.name() : m.getName();
15 |
16 | function.getCallTimeout().setValue(annotation.timeout());
17 | function.setAttributes(new HashMap<>());
18 | function.getAttributes().put(AbstractOrganizableObject.NAME, functionName);
19 | function.setPlan(plan);
20 | return function;
21 | }
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-composite/step-functions-plugins-composite-def/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-composite/step-functions-plugins-composite-def/src/test/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-controller-def/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-controller-def/src/test/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/errorHandler.groovy:
--------------------------------------------------------------------------------
1 | output.setError("Error handler called")
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/errorHandler.js:
--------------------------------------------------------------------------------
1 | Java.type('java.lang.System').getProperties().put("errorHandler", "executed");
2 | output.setError(exception.getMessage())
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/errorScript.js:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | *******************************************************************************/
19 | INVALID SCRIPT
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/errorScriptWithAttachment.groovy:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | *******************************************************************************/
19 | output.setError("E",new java.lang.Exception());
20 | INVALID;
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/invalidExtension.dummy:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/invalidExtension.dummy
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/noextension:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/noextension
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/testGroovy1.groovy:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | *******************************************************************************/
19 | output.add("key1",input.key1.getString())
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/testGroovyUTF8.groovy:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | *******************************************************************************/
19 | output.add('key1','kéÿ1')
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/testPython.py:
--------------------------------------------------------------------------------
1 | output.add("key1",input.getString("key1"))
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-def/src/test/resources/scripts/throwable.groovy:
--------------------------------------------------------------------------------
1 | assert false
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-handler/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-handler/src/test/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-handler/src/test/resources/scripts/errorHandler.groovy:
--------------------------------------------------------------------------------
1 | output.setError("Error handler called")
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-handler/src/test/resources/scripts/errorScript.js:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | *******************************************************************************/
19 | INVALID SCRIPT
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-handler/src/test/resources/scripts/errorScriptWithAttachment.groovy:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | *******************************************************************************/
19 | output.setError("E",new java.lang.Exception());
20 | INVALID;
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-handler/src/test/resources/scripts/testGroovyUTF8.groovy:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | *******************************************************************************/
19 | output.add('key1','kéÿ1')
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-java/step-functions-plugins-java-handler/src/test/resources/scripts/throwable.groovy:
--------------------------------------------------------------------------------
1 | assert false
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-jmeter/step-functions-plugins-jmeter-def/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-jmeter/step-functions-plugins-jmeter-handler/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions-plugins/step-functions-plugins-jmeter/step-functions-plugins-jmeter-local-handler/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions/step-functions-client-api/src/main/java/step/functions/execution/TokenLifecycleInterceptor.java:
--------------------------------------------------------------------------------
1 | package step.functions.execution;
2 |
3 | /**
4 | * Interface used for intercepting token creation and disposal.
5 | *
6 | * On returning a token (i.e., when the implementation has finished using the token), no complicated operations should be performed,
7 | * and are must be taken not to (inadvertently) throw Exceptions.
8 | *
9 | * On getting a token, the method may (knowingly) throw an exception,
10 | * in which case the entire token retrieval process is aborted, and thus the execution
11 | * will not take place.
12 | *
13 | */
14 | public interface TokenLifecycleInterceptor {
15 | void onReturnTokenHandle(String tokenHandleId);
16 |
17 | void onGetTokenHandle(String tokenHandleId) throws Exception;
18 | }
19 |
--------------------------------------------------------------------------------
/step-functions/step-functions-client/src/main/resources/.gitignore:
--------------------------------------------------------------------------------
1 | *.jar
--------------------------------------------------------------------------------
/step-functions/step-functions-client/src/test/java/step/functions/runner/TestFunction.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.functions.runner;
20 |
21 | import step.functions.Function;
22 |
23 | public class TestFunction extends Function {
24 |
25 | }
26 |
--------------------------------------------------------------------------------
/step-functions/step-functions-handler/src/main/java/org/glassfish/json/OutputJsonProviderImpl.java:
--------------------------------------------------------------------------------
1 | package org.glassfish.json;
2 |
3 | import jakarta.json.JsonBuilderFactory;
4 | import org.glassfish.json.api.BufferPool;
5 |
6 | import java.util.Map;
7 |
8 | public class OutputJsonProviderImpl extends JsonProviderImpl {
9 |
10 | @Override
11 | public JsonBuilderFactory createBuilderFactory(Map config) {
12 | BufferPool pool = new BufferPoolImpl();
13 | boolean rejectDuplicateKeys = false;
14 | if (config != null) {
15 | if (config.containsKey(BufferPool.class.getName())) {
16 | pool = (BufferPool) config.get(BufferPool.class.getName());
17 | }
18 | rejectDuplicateKeys = JsonProviderImpl.isRejectDuplicateKeysEnabled(config);
19 | }
20 | return new OutputJsonBuilderFactoryImpl(pool, rejectDuplicateKeys);
21 | }
22 |
23 |
24 | }
25 |
--------------------------------------------------------------------------------
/step-functions/step-functions-handler/src/main/java/org/glassfish/json/OutputJsonStringImpl.java:
--------------------------------------------------------------------------------
1 | package org.glassfish.json;
2 |
3 | import jakarta.json.JsonString;
4 | import jakarta.json.JsonValue;
5 |
6 | public class OutputJsonStringImpl implements JsonString {
7 |
8 | private final String value;
9 |
10 | OutputJsonStringImpl(String value) {
11 | this.value = value;
12 | }
13 |
14 | @Override
15 | public String getString() {
16 | return value;
17 | }
18 |
19 | @Override
20 | public CharSequence getChars() {
21 | return value;
22 | }
23 |
24 | @Override
25 | public JsonValue.ValueType getValueType() {
26 | return JsonValue.ValueType.STRING;
27 | }
28 |
29 | @Override
30 | public int hashCode() {
31 | return getString().hashCode();
32 | }
33 |
34 | @Override
35 | public boolean equals(Object obj) {
36 | if (this == obj){
37 | return true;
38 | }
39 | if (!(obj instanceof JsonString)) {
40 | return false;
41 | }
42 | JsonString other = (JsonString)obj;
43 | return getString().equals(other.getString());
44 | }
45 |
46 | @Override
47 | public String toString() {
48 | return value;
49 | }
50 | }
51 |
--------------------------------------------------------------------------------
/step-functions/step-functions-handler/src/main/java/step/functions/handler/MeasureTypes.java:
--------------------------------------------------------------------------------
1 | package step.functions.handler;
2 |
3 | public class MeasureTypes {
4 |
5 | public static final String ATTRIBUTE_TYPE = "type";
6 | public static final String TYPE_KEYWORD = "keyword";
7 | public static final String TYPE_CUSTOM = "custom";
8 | }
9 |
--------------------------------------------------------------------------------
/step-functions/step-functions-handler/src/main/resources/META-INF/services/javax.json.spi.JsonProvider:
--------------------------------------------------------------------------------
1 | javax.org.glassfish.json.JsonProviderImpl
--------------------------------------------------------------------------------
/step-functions/step-functions-handler/src/test/resources/testResource.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-functions/step-functions-handler/src/test/resources/testResource.jar
--------------------------------------------------------------------------------
/step-functions/step-functions-package-client/pom.xml:
--------------------------------------------------------------------------------
1 |
8 |
9 | 4.0.0
10 |
11 | step-functions-package-client
12 | jar
13 |
14 |
15 | ch.exense.step
16 | step-functions
17 | 0.0.0-SNAPSHOT
18 |
19 |
20 |
21 |
22 | ch.exense.step
23 | step-controller-remote-client
24 | ${project.version}
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/step-functions/step-functions-package-controller/src/main/java/step/functions/packages/migration/MigrationTasksRegistrationPlugin.java:
--------------------------------------------------------------------------------
1 | package step.functions.packages.migration;
2 |
3 | import step.core.GlobalContext;
4 | import step.core.plugins.AbstractControllerPlugin;
5 | import step.core.plugins.Plugin;
6 | import step.migration.MigrationManager;
7 | import step.migration.tasks.MigrationManagerTasksPlugin;
8 |
9 | /**
10 | * This plugin is responsible for the registration of the migration tasks
11 | */
12 | @Plugin(dependencies= {MigrationManagerTasksPlugin.class})
13 | public class MigrationTasksRegistrationPlugin extends AbstractControllerPlugin {
14 |
15 | @Override
16 | public void serverStart(GlobalContext context) throws Exception {
17 | MigrationManager migrationManager = context.get(MigrationManager.class);
18 | migrationManager.register(ScreenTemplateFunctionTableExtensionsMigrationTask.class);
19 | migrationManager.register(PlansInCompositeFunctionsMigrationTask.class);
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/step-functions/step-functions-package/.gitignore:
--------------------------------------------------------------------------------
1 | temp/
2 | /resources/
3 | /src/test/resources/local/java-plugin-handler-test.jar
4 |
--------------------------------------------------------------------------------
/step-functions/step-functions-package/src/main/java/step/functions/packages/FunctionPackageAccessor.java:
--------------------------------------------------------------------------------
1 | package step.functions.packages;
2 |
3 | import step.core.accessors.Accessor;
4 |
5 | public interface FunctionPackageAccessor extends Accessor {
6 |
7 | }
--------------------------------------------------------------------------------
/step-functions/step-functions-package/src/main/java/step/functions/packages/FunctionPackageAccessorImpl.java:
--------------------------------------------------------------------------------
1 | package step.functions.packages;
2 |
3 | import step.core.accessors.AbstractAccessor;
4 | import step.core.collections.Collection;
5 |
6 | public class FunctionPackageAccessorImpl extends AbstractAccessor implements FunctionPackageAccessor {
7 |
8 | public FunctionPackageAccessorImpl(Collection collectionDriver) {
9 | super(collectionDriver);
10 | }
11 | }
12 |
--------------------------------------------------------------------------------
/step-functions/step-functions-package/src/main/java/step/functions/packages/FunctionPackageHandler.java:
--------------------------------------------------------------------------------
1 | package step.functions.packages;
2 |
3 | import java.util.List;
4 |
5 | import step.core.objectenricher.ObjectEnricher;
6 | import step.functions.Function;
7 |
8 | public interface FunctionPackageHandler {
9 |
10 | boolean isValidForPackage(FunctionPackage functionPackage);
11 |
12 | List buildFunctions(FunctionPackage functionPackage, boolean preview, ObjectEnricher objectEnricher) throws Exception;
13 |
14 | }
--------------------------------------------------------------------------------
/step-functions/step-functions-package/src/main/java/step/functions/packages/InMemoryFunctionPackageAccessorImpl.java:
--------------------------------------------------------------------------------
1 | package step.functions.packages;
2 |
3 | import step.core.accessors.AbstractAccessor;
4 | import step.core.collections.inmemory.InMemoryCollection;
5 |
6 | public class InMemoryFunctionPackageAccessorImpl extends AbstractAccessor
7 | implements FunctionPackageAccessor {
8 |
9 | public InMemoryFunctionPackageAccessorImpl() {
10 | super(new InMemoryCollection());
11 | }
12 |
13 | }
--------------------------------------------------------------------------------
/step-functions/step-functions-package/src/main/java/step/functions/packages/UnsupportedFunctionPackageType.java:
--------------------------------------------------------------------------------
1 | package step.functions.packages;
2 |
3 | @SuppressWarnings("serial")
4 | public class UnsupportedFunctionPackageType extends Exception {
5 |
6 | public UnsupportedFunctionPackageType(String message) {
7 | super(message);
8 | }
9 |
10 | }
11 |
--------------------------------------------------------------------------------
/step-functions/step-functions-package/src/main/java/step/functions/packages/handlers/FunctionList.java:
--------------------------------------------------------------------------------
1 | package step.functions.packages.handlers;
2 |
3 | import java.util.ArrayList;
4 |
5 | import step.functions.Function;
6 |
7 | public class FunctionList {
8 |
9 | public String exception;
10 | public ArrayList functions;
11 |
12 | public FunctionList() {
13 | super();
14 | functions = new ArrayList();
15 | }
16 |
17 | public ArrayList getFunctions() {
18 | return functions;
19 | }
20 |
21 | public void setFunctions(ArrayList functions) {
22 | this.functions = functions;
23 | }
24 |
25 | public String getException() {
26 | return exception;
27 | }
28 |
29 | public void setException(String exception) {
30 | this.exception = exception;
31 | }
32 | }
33 |
--------------------------------------------------------------------------------
/step-functions/step-functions-package/src/test/resources/local/java-plugin-handler-test.jar.json:
--------------------------------------------------------------------------------
1 | {
2 | "attributes": {
3 | "attribute1": "@ref1",
4 | "attribute2": "value2",
5 | "attributeI18n": "Äöüßêï"
6 | }
7 | }
--------------------------------------------------------------------------------
/step-ide/.gitignore:
--------------------------------------------------------------------------------
1 | db/
2 | filemanager/
3 | resources/
4 |
--------------------------------------------------------------------------------
/step-maven-plugin/src/test/resources/step/plugins/maven/test-file-jar-with-dependencies.jar:
--------------------------------------------------------------------------------
1 | jar-with-dependencies content
--------------------------------------------------------------------------------
/step-maven-plugin/src/test/resources/step/plugins/maven/test-file-jar.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-maven-plugin/src/test/resources/step/plugins/maven/test-file-jar.jar
--------------------------------------------------------------------------------
/step-node/.editorconfig:
--------------------------------------------------------------------------------
1 | # EditorConfig helps developers define and maintain consistent
2 | # coding styles between different editors and IDEs
3 | # editorconfig.org
4 |
5 | root = true
6 |
7 |
8 | [*]
9 |
10 | # Change these settings to your own preference
11 | indent_style = space
12 | indent_size = 2
13 |
14 | # We recommend you to keep these unchanged
15 | end_of_line = lf
16 | charset = utf-8
17 | trim_trailing_whitespace = true
18 | insert_final_newline = true
19 |
20 | [*.md]
21 | trim_trailing_whitespace = false
22 |
--------------------------------------------------------------------------------
/step-node/.gitignore:
--------------------------------------------------------------------------------
1 | examples/my-keyword-library/chromedriver.exe
2 | package-lock.json
--------------------------------------------------------------------------------
/step-node/examples/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules/
2 | .npm
3 | !/bin
--------------------------------------------------------------------------------
/step-node/examples/my-keyword-library/.eslintrc.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | 'extends': 'standard'
3 | }
4 |
--------------------------------------------------------------------------------
/step-node/examples/my-keyword-library/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules/
2 | .npm
3 | !/bin
4 | package-lock.json
--------------------------------------------------------------------------------
/step-node/examples/my-keyword-library/AgentConf.json:
--------------------------------------------------------------------------------
1 | {
2 | "agentPort": "8082",
3 | "gridHost": "http://localhost:8081",
4 | "registrationPeriod": 1000,
5 | "tokenGroups": [
6 | {
7 | "capacity": 10,
8 | "tokenConf": {
9 | "attributes": {},
10 | "properties": {}
11 | }
12 | }
13 | ],
14 | "properties": {
15 | "keywords": "keywords/keywords.js;"
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/step-node/examples/my-keyword-library/index.js:
--------------------------------------------------------------------------------
1 | const runner = require('step-node-agent').runner({'google.url':'http://www.google.com/ncr'})
2 | const assert = require('assert')
3 |
4 | ;(async () => {
5 | var output = await runner.run('Open_Chrome', {})
6 | assert.equal(output.payload.result, 'OK')
7 | output = await runner.run('Google_Search', { search: 'djigger' })
8 | assert.equal(output.payload.result, 'OK')
9 | await runner.run('Google_Search', { search: 'exense step' })
10 | assert.equal(output.payload.result, 'OK')
11 | })()
12 |
--------------------------------------------------------------------------------
/step-node/examples/my-keyword-library/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "my-keyword-library",
3 | "version": "1.0.0",
4 | "description": "",
5 | "main": "index.js",
6 | "scripts": {
7 | "eslint": "node_modules/.bin/eslint .",
8 | "test": "node index.js"
9 | },
10 | "author": "Jérôme Comte",
11 | "license": "ISC",
12 | "dependencies": {
13 | "npm": "^6.14.15",
14 | "selenium-webdriver": "^3.6.0",
15 | "step-node-agent": "^0.9.5"
16 | },
17 | "devDependencies": {
18 | "eslint": "^4.18.2",
19 | "eslint-config-standard": "^11.0.0",
20 | "eslint-plugin-import": "^2.9.0",
21 | "eslint-plugin-node": "^6.0.1",
22 | "eslint-plugin-promise": "^3.7.0",
23 | "eslint-plugin-standard": "^3.0.1",
24 | "husky": "^0.14.3"
25 | }
26 | }
27 |
--------------------------------------------------------------------------------
/step-node/step-node-agent/.eslintrc.js:
--------------------------------------------------------------------------------
1 | module.exports = {
2 | 'extends': 'standard'
3 | }
4 |
--------------------------------------------------------------------------------
/step-node/step-node-agent/.gitignore:
--------------------------------------------------------------------------------
1 | node_modules/
2 | .npm
3 | !/bin
4 | filemanager/work/
--------------------------------------------------------------------------------
/step-node/step-node-agent/.vscode/launch.json:
--------------------------------------------------------------------------------
1 | {
2 | // Use IntelliSense to learn about possible attributes.
3 | // Hover to view descriptions of existing attributes.
4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5 | "version": "0.2.0",
6 | "configurations": [
7 |
8 | {
9 | "name": "Attach To npm",
10 | "type": "node",
11 | "request": "attach",
12 | "port": 9229,
13 | "address": "localhost",
14 | "restart": false,
15 | "sourceMaps": false,
16 | "outDir": null,
17 | "localRoot": "${workspaceRoot}",
18 | "remoteRoot": "${workspaceRoot}"
19 | }
20 | ]
21 | }
22 |
--------------------------------------------------------------------------------
/step-node/step-node-agent/AgentConf.json:
--------------------------------------------------------------------------------
1 | {
2 | "agentPort": "8082",
3 | "gridHost": "http://localhost:8081",
4 | "registrationPeriod": 1000,
5 | "tokenGroups": [
6 | {
7 | "capacity": 10,
8 | "tokenConf": {
9 | "attributes": {},
10 | "properties": {"myProp1":"myProp1"}
11 | }
12 | }
13 | ],
14 | "properties": {
15 | "myProp1":"myDefaultValue",
16 | "myProp2":"myValue2",
17 | "keywords": "keywords/keywords.js;"
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/step-node/step-node-agent/AgentConf.yaml:
--------------------------------------------------------------------------------
1 | agentPort: '8082'
2 | gridHost: http://localhost:8081
3 | registrationPeriod: 1000
4 | tokenGroups:
5 | - capacity: 10
6 | tokenConf:
7 | attributes: {}
8 | properties:
9 | myProp1: myProp1
10 | properties:
11 | myProp1: myDefaultValue
12 | myProp2: myValue2
13 | keywords: keywords/keywords.js;
--------------------------------------------------------------------------------
/step-node/step-node-agent/README:
--------------------------------------------------------------------------------
1 | Official documentation available at: https://step.exense.ch/knowledgebase/plugins/nodejs/
2 |
3 | To run locally: npm i; npm start
4 |
--------------------------------------------------------------------------------
/step-node/step-node-agent/api/routes/routes.js:
--------------------------------------------------------------------------------
1 | 'use strict'
2 | module.exports = function (app, agentContext) {
3 | const Controller = require('../controllers/controller')
4 | const FileManager = require('../filemanager/filemanager')
5 | const controller = new Controller(agentContext, new FileManager(agentContext))
6 |
7 | app.route('/running').get(controller.isRunning)
8 | app.route('/token/:tokenId/reserve').get(controller.reserveToken)
9 | app.route('/token/:tokenId/release').get(controller.releaseToken)
10 | app.route('/token/:tokenId/process').post(controller.process)
11 | app.route('/token/:tokenId/interrupt-execution').post(controller.interruptExecution)
12 | }
13 |
--------------------------------------------------------------------------------
/step-node/step-node-agent/api/runner/runner.js:
--------------------------------------------------------------------------------
1 | module.exports = function (properties = {}) {
2 | const tokenId = 'local'
3 |
4 | const agentContext = {tokens: [], tokenSessions: {}, properties: properties}
5 | agentContext.tokenSessions[tokenId] = {}
6 |
7 | var fileManager = {
8 | loadOrGetKeywordFile: function (url, fileId, fileVersion, keywordName) {
9 | return new Promise(function (resolve, reject) {
10 | resolve('.')
11 | })
12 | }
13 | }
14 |
15 | const Controller = require('../controllers/controller')
16 | const controller = new Controller(agentContext, fileManager)
17 |
18 | const api = {}
19 |
20 | api.run = function (keywordName, input) {
21 | return new Promise(resolve => {
22 | controller.process_(tokenId, keywordName, input, properties, function (output) { resolve(output.payload) })
23 | })
24 | }
25 |
26 | return api
27 | }
28 |
--------------------------------------------------------------------------------
/step-node/step-node-agent/bin/step-node-agent:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env node
2 | require('../server.js');
--------------------------------------------------------------------------------
/step-node/step-node-agent/index.js:
--------------------------------------------------------------------------------
1 | const runner = require('./api/runner/runner')
2 | exports.runner = runner
3 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/.gitignore:
--------------------------------------------------------------------------------
1 | resources/
2 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/main/java/step/artefacts/Aggregator.java:
--------------------------------------------------------------------------------
1 | package step.artefacts;
2 |
3 | import java.util.function.Function;
4 |
5 | public enum Aggregator {
6 |
7 | AVG(Aggregation::getAvg, "Average"),
8 | MAX(Aggregation::getMax, "Max"),
9 | MIN(Aggregation::getMin, "Min"),
10 | COUNT(Aggregation::getCount, "Count"),
11 | SUM(Aggregation::getSum, "Sum");
12 |
13 | private Function valueFunction;
14 | private String description;
15 |
16 | private Aggregator(Function supplier, String description) {
17 | this.valueFunction = supplier;
18 | this.description = description;
19 | }
20 |
21 | public Function getValueFunction() {
22 | return valueFunction;
23 | }
24 |
25 | public String getDescription() {
26 | return description;
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/main/java/step/artefacts/handlers/functions/NoMatchingTokenPoolException.java:
--------------------------------------------------------------------------------
1 | /*
2 | * Copyright (C) 2024, exense GmbH
3 | *
4 | * This file is part of Step
5 | *
6 | * Step is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * Step is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with Step. If not, see .
18 | */
19 |
20 | package step.artefacts.handlers.functions;
21 |
22 | public class NoMatchingTokenPoolException extends Exception {
23 | }
24 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/main/java/step/artefacts/reports/BeforeSequenceReportNode.java:
--------------------------------------------------------------------------------
1 | package step.artefacts.reports;
2 |
3 | import step.core.artefacts.reports.ReportNode;
4 |
5 | /**
6 | * Required for the housekeeping job (executions created prior to the deprecation / removal of this class)
7 | * Used only for report node deserialization
8 | */
9 | @Deprecated
10 | public class BeforeSequenceReportNode extends ReportNode {
11 |
12 | @Override
13 | public boolean setVariableInParentScope() {
14 | return true;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/main/java/step/artefacts/reports/BeforeThreadReportNode.java:
--------------------------------------------------------------------------------
1 | package step.artefacts.reports;
2 |
3 | import step.core.artefacts.reports.ReportNode;
4 |
5 | /**
6 | * Required for the housekeeping job (executions created prior to the deprecation / removal of this class)
7 | * Used only for report node deserialization
8 | */
9 | @Deprecated
10 | public class BeforeThreadReportNode extends ReportNode {
11 |
12 | @Override
13 | public boolean setVariableInParentScope() {
14 | return true;
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/main/java/step/artefacts/reports/PerformanceAssertReportNode.java:
--------------------------------------------------------------------------------
1 | package step.artefacts.reports;
2 |
3 | import step.core.artefacts.reports.ReportNode;
4 |
5 | public class PerformanceAssertReportNode extends ReportNode {
6 |
7 | }
8 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/main/java/step/plans/assertions/PerformanceAssertSession.java:
--------------------------------------------------------------------------------
1 | package step.plans.assertions;
2 |
3 | import java.util.Map.Entry;
4 | import java.util.Set;
5 | import java.util.concurrent.ConcurrentHashMap;
6 |
7 | import step.artefacts.Aggregation;
8 | import step.core.reports.Measure;
9 |
10 | public class PerformanceAssertSession {
11 |
12 | private final ConcurrentHashMap aggregations = new ConcurrentHashMap<>();
13 |
14 | public final void addMeasure(Measure measure) {
15 | Aggregation aggregation = aggregations.computeIfAbsent(measure.getName(), name->new Aggregation(name));
16 | aggregation.addMeasure(measure);
17 | }
18 |
19 | public Set> getAggregations() {
20 | return aggregations.entrySet();
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/java/step/artefacts/handlers/functions/test/MyFunction.java:
--------------------------------------------------------------------------------
1 | package step.artefacts.handlers.functions.test;
2 |
3 | import step.functions.Function;
4 | import step.functions.io.Input;
5 | import step.functions.io.Output;
6 |
7 | import javax.json.JsonObject;
8 |
9 | public class MyFunction extends Function {
10 |
11 | private final java.util.function.Function, Output> handler;
12 |
13 | public MyFunction(java.util.function.Function, Output> handler) {
14 | this.handler = handler;
15 | }
16 |
17 | public java.util.function.Function, Output> getHandler() {
18 | return handler;
19 | }
20 |
21 | @Override
22 | public boolean requiresLocalExecution() {
23 | return false;
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/java/step/artefacts/handlers/functions/test/MyFunctionHandler.java:
--------------------------------------------------------------------------------
1 | package step.artefacts.handlers.functions.test;
2 |
3 | import step.functions.handler.JsonBasedFunctionHandler;
4 | import step.functions.io.Input;
5 | import step.functions.io.Output;
6 |
7 | import javax.json.JsonObject;
8 | import java.util.Map;
9 | import java.util.UUID;
10 | import java.util.concurrent.ConcurrentHashMap;
11 | import java.util.function.Function;
12 |
13 | public class MyFunctionHandler extends JsonBasedFunctionHandler {
14 |
15 | public static final String HANDLER_ID = "handlerId";
16 | private static Map, Output>> handlers = new ConcurrentHashMap<>();
17 |
18 | public static String registerHandler(Function, Output> handler) {
19 | String id = UUID.randomUUID().toString();
20 | handlers.put(id, handler);
21 | return id;
22 | }
23 |
24 | @Override
25 | public Output handle(Input input) throws Exception {
26 | return handlers.remove(input.getProperties().get(HANDLER_ID)).apply(input);
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/java/step/artefacts/handlers/functions/test/MyFunctionType.java:
--------------------------------------------------------------------------------
1 | package step.artefacts.handlers.functions.test;
2 |
3 | import step.core.AbstractStepContext;
4 | import step.functions.type.AbstractFunctionType;
5 |
6 | import java.util.Map;
7 |
8 | public class MyFunctionType extends AbstractFunctionType {
9 |
10 | @Override
11 | public String getHandlerChain(MyFunction function) {
12 | return MyFunctionHandler.class.getName();
13 | }
14 |
15 | @Override
16 | public HandlerProperties getHandlerProperties(MyFunction function, AbstractStepContext executionContext) {
17 | String handlerId = MyFunctionHandler.registerHandler(function.getHandler());
18 | return new HandlerProperties(Map.of(MyFunctionHandler.HANDLER_ID, handlerId));
19 | }
20 |
21 | @Override
22 | public MyFunction newFunction() {
23 | return new MyFunction(null);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/java/step/artefacts/handlers/functions/test/MyKeyword.java:
--------------------------------------------------------------------------------
1 | package step.artefacts.handlers.functions.test;
2 |
3 | import step.handlers.javahandler.AbstractKeyword;
4 | import step.handlers.javahandler.Keyword;
5 |
6 | public class MyKeyword extends AbstractKeyword {
7 |
8 | @Keyword
9 | public void test() {
10 |
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/BigExcel.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/BigExcel.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/Excel-XLOOKUP.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/Excel-XLOOKUP.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/Excel-large2.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/Excel-large2.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/Excel1.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/Excel1.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/Excel2.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/Excel2.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/ExcelDataPool.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/ExcelDataPool.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/ExcelDataPoolImmutable.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/ExcelDataPoolImmutable.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/ExcelDataPoolValueChanged.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/ExcelDataPoolValueChanged.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/File.csv:
--------------------------------------------------------------------------------
1 | Col1,Col2
2 | row11,row12
3 | row21,row22
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/File.txt:
--------------------------------------------------------------------------------
1 | Line 1
2 | Line 2
3 | Line 3
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/File.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/File.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/File2.csv:
--------------------------------------------------------------------------------
1 | Col1,Col2,Col3,Col4,Col5
2 | row11,row12,row13,,
3 | row21,row22,row23,,
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/WriteTest.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/WriteTest.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/WriteTest2.xlsx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/WriteTest2.xlsx
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/empty.csv:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/empty.csv
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/emptyFolder/.gitignore:
--------------------------------------------------------------------------------
1 | # Ignore everything in this directory
2 | *
3 | # Except this file
4 | !.gitignore
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/exportTest/test:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-plans/step-plans-base-artefacts/src/test/resources/exportTest/test
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/folder/File.txt:
--------------------------------------------------------------------------------
1 | Line 1
2 | Line 2
3 | Line 3
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/folder/File2.txt:
--------------------------------------------------------------------------------
1 | Line 1
2 | Line 2
3 | Line 3
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/step/reporting/TEST-JUnit4ReportWriterTest-testSeveralTestsuites-expected.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/step-plans/step-plans-base-artefacts/src/test/resources/step/reporting/TEST-JUnit4ReportWriterTest-testSimpleSequence-expected.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/artefacts/reports/aggregated/AggregatedReport.java:
--------------------------------------------------------------------------------
1 | package step.core.artefacts.reports.aggregated;
2 |
3 | public class AggregatedReport {
4 | public AggregatedReportView aggregatedReportView;
5 | public String resolvedPartialPath;
6 |
7 | public AggregatedReport(AggregatedReportView aggregatedReportView) {
8 | this.aggregatedReportView = aggregatedReportView;
9 | }
10 |
11 | public AggregatedReport() {
12 |
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/artefacts/reports/aggregated/FlatAggregatedReport.java:
--------------------------------------------------------------------------------
1 | package step.core.artefacts.reports.aggregated;
2 |
3 | import java.util.List;
4 |
5 | public class FlatAggregatedReport {
6 | public List aggregatedReportViews;
7 |
8 | public FlatAggregatedReport(List aggregatedReportViews) {
9 | this.aggregatedReportViews = aggregatedReportViews;
10 | }
11 |
12 | public FlatAggregatedReport() {
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/artefacts/reports/resolvedplan/ResolvedChildren.java:
--------------------------------------------------------------------------------
1 | package step.core.artefacts.reports.resolvedplan;
2 |
3 | import step.core.artefacts.AbstractArtefact;
4 | import step.core.artefacts.reports.ParentSource;
5 |
6 | import java.util.List;
7 |
8 | public class ResolvedChildren {
9 |
10 | public ParentSource parentSource;
11 | public List children;
12 | public String artefactPath;
13 |
14 | public ResolvedChildren(ParentSource parentSource, List children, String artefactPath) {
15 | this.parentSource = parentSource;
16 | this.children = children;
17 | this.artefactPath = artefactPath;
18 | }
19 | }
20 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/DeprovisioningException.java:
--------------------------------------------------------------------------------
1 | package step.core.execution;
2 |
3 | import step.core.plugins.exceptions.PluginCriticalException;
4 |
5 | public class DeprovisioningException extends PluginCriticalException {
6 | public DeprovisioningException(String string, Throwable e) {
7 | super(string, e);
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/OperationMode.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.core.execution;
20 |
21 | public enum OperationMode {
22 |
23 | CONTROLLER,
24 |
25 | LOCAL;
26 | }
27 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/ProvisioningException.java:
--------------------------------------------------------------------------------
1 | package step.core.execution;
2 |
3 | import step.core.plugins.exceptions.PluginCriticalException;
4 |
5 | public class ProvisioningException extends PluginCriticalException {
6 |
7 | public ProvisioningException(String message) {
8 | super(message);
9 | }
10 |
11 | public ProvisioningException(String string, Throwable e) {
12 | super(string, e);
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/ReportNodeEventListener.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.core.execution;
20 |
21 | public interface ReportNodeEventListener {
22 |
23 | public void onUpdate();
24 |
25 | public void onDestroy();
26 | }
27 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/model/ExecutionLauncher.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.core.execution.model;
20 |
21 | public interface ExecutionLauncher {
22 | String execute(ExecutionParameters executionParameters);
23 | }
24 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/model/ExecutionMode.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.core.execution.model;
20 |
21 | public enum ExecutionMode {
22 |
23 | RUN,
24 |
25 | SIMULATION;
26 | }
27 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/model/ExecutionProvider.java:
--------------------------------------------------------------------------------
1 | package step.core.execution.model;
2 |
3 | public interface ExecutionProvider {
4 |
5 | Execution get(String executionId);
6 | }
7 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/execution/model/ReportExportStatus.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.core.execution.model;
20 |
21 | public enum ReportExportStatus {
22 |
23 | SUCCESSFUL,
24 |
25 | FAILED;
26 | }
27 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/plans/PlanCompiler.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.core.plans;
20 |
21 | public interface PlanCompiler {
22 |
23 | public T compile(T plan) throws PlanCompilerException;
24 | }
25 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/scheduler/CronExclusion.java:
--------------------------------------------------------------------------------
1 | package step.core.scheduler;
2 |
3 | public class CronExclusion {
4 |
5 | private String cronExpression;
6 | private String description;
7 |
8 | public CronExclusion() {
9 | }
10 |
11 | public CronExclusion(String cronExpression, String description) {
12 | this.cronExpression = cronExpression;
13 | this.description = description;
14 | }
15 |
16 | public String getCronExpression() {
17 | return cronExpression;
18 | }
19 |
20 | public void setCronExpression(String cronExpression) {
21 | this.cronExpression = cronExpression;
22 | }
23 |
24 | public String getDescription() {
25 | return description;
26 | }
27 |
28 | public void setDescription(String description) {
29 | this.description = description;
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/core/variables/VariableType.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.core.variables;
20 |
21 | public enum VariableType {
22 |
23 | IMMUTABLE,
24 |
25 | NORMAL;
26 | }
27 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/datapool/DataSetHandle.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright (C) 2020, exense GmbH
3 | *
4 | * This file is part of STEP
5 | *
6 | * STEP is free software: you can redistribute it and/or modify
7 | * it under the terms of the GNU Affero General Public License as published by
8 | * the Free Software Foundation, either version 3 of the License, or
9 | * (at your option) any later version.
10 | *
11 | * STEP is distributed in the hope that it will be useful,
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 | * GNU Affero General Public License for more details.
15 | *
16 | * You should have received a copy of the GNU Affero General Public License
17 | * along with STEP. If not, see .
18 | ******************************************************************************/
19 | package step.datapool;
20 |
21 | public interface DataSetHandle {
22 |
23 | public Object next();
24 |
25 | public void addRow(Object row);
26 | }
27 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/engine/execution/ExecutionVeto.java:
--------------------------------------------------------------------------------
1 | package step.engine.execution;
2 |
3 | public class ExecutionVeto {
4 | public final String reason;
5 |
6 | public ExecutionVeto(String reason) {
7 | this.reason = reason;
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/step-plans/step-plans-core/src/main/java/step/engine/execution/ExecutionVetoer.java:
--------------------------------------------------------------------------------
1 | package step.engine.execution;
2 |
3 | import step.core.execution.ExecutionContext;
4 |
5 | import java.util.List;
6 |
7 | public interface ExecutionVetoer {
8 | List getExecutionVetoes(ExecutionContext context);
9 | }
10 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/plans/nl/RootArtefactType.java:
--------------------------------------------------------------------------------
1 | package step.plans.nl;
2 |
3 | import step.core.artefacts.AbstractArtefact;
4 |
5 | import java.util.function.Supplier;
6 |
7 | /**
8 | * Enumeration defining the supported root artefacts for plain-text plans.
9 | * This corresponds to the selections available in the UI.
10 | */
11 | public enum RootArtefactType {
12 | // Note: The names are Camel-cased by design, so they align with the class and template names used in the UI.
13 | Sequence(step.artefacts.Sequence::new),
14 | TestCase(step.artefacts.TestCase::new),
15 | TestScenario(step.artefacts.TestScenario::new),
16 | TestSet(step.artefacts.TestSet::new),
17 | ThreadGroup(step.artefacts.ThreadGroup::new);
18 |
19 | private final Supplier artefactConstructor;
20 |
21 | public AbstractArtefact createRootArtefact() {
22 | return artefactConstructor.get();
23 | }
24 |
25 | RootArtefactType(Supplier artefactConstructor) {
26 | this.artefactConstructor = artefactConstructor;
27 | }
28 | }
29 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/description/DescriptionStep.g4:
--------------------------------------------------------------------------------
1 | grammar DescriptionStep;
2 |
3 | @header {
4 | package step.repositories.parser.description;
5 | }
6 |
7 | parse
8 | : expr EOF
9 | ;
10 |
11 | expr
12 | : (keywordExpression|setExpression|functionDeclarationExpression|functionDeclarationEndExpression)
13 | ;
14 |
15 | /* Expressions */
16 | keywordExpression : keywordName keywordParameter*;
17 | setExpression : 'Set' assignment+;
18 | functionDeclarationExpression : 'Function' keywordParameter*;
19 | functionDeclarationEndExpression : 'EndFunction';
20 |
21 | assignment : attributeName EQ setValue;
22 |
23 | keywordParameter
24 | : attributeName EQ attributeValue
25 | ;
26 |
27 | keywordName : (STRING|WORD);
28 |
29 | attributeName : (WORD|STRING);
30 |
31 | attributeValue : STRING;
32 |
33 | setValue : (WORD|STRING);
34 |
35 | EQ : '=';
36 |
37 | WORD: (~[=" \u00A0\t\r\n])+ ;
38 |
39 | STRING
40 | : '"' (~["\r\n] | EscapeSequence)* '"'
41 | ;
42 |
43 | fragment EscapeSequence
44 | : '\\' ["]
45 | ;
46 |
47 | SPACE
48 | : [ \u00A0\t\r\n] -> skip
49 | ;
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/description/DescriptionStep.tokens:
--------------------------------------------------------------------------------
1 | T__0=1
2 | T__1=2
3 | T__2=3
4 | EQ=4
5 | WORD=5
6 | STRING=6
7 | SPACE=7
8 | 'Set'=1
9 | 'Function'=2
10 | 'EndFunction'=3
11 | '='=4
12 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/description/DescriptionStepLexer.tokens:
--------------------------------------------------------------------------------
1 | T__0=1
2 | T__1=2
3 | T__2=3
4 | EQ=4
5 | WORD=5
6 | STRING=6
7 | SPACE=7
8 | 'Set'=1
9 | 'Function'=2
10 | 'EndFunction'=3
11 | '='=4
12 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/description/ParseGrammar - Description.launch:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/expected/Expected Gen Launch.run.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/expected/ExpectedStep.tokens:
--------------------------------------------------------------------------------
1 | T__0=1
2 | T__1=2
3 | NOT=3
4 | EQ=4
5 | REGEX=5
6 | CONTAINS=6
7 | BEGINS=7
8 | ENDS=8
9 | GREATER_THAN_OR_EQUALS=9
10 | GREATER_THAN=10
11 | LESS_THAN_OR_EQUALS=11
12 | LESS_THAN=12
13 | IS_NULL=13
14 | NUM=14
15 | BOOL=15
16 | WORD=16
17 | STRING=17
18 | SPACE=18
19 | 'Set'=1
20 | 'Export'=2
21 | '='=4
22 | '~'=5
23 | 'contains'=6
24 | 'beginsWith'=7
25 | 'endsWith'=8
26 | '>='=9
27 | '>'=10
28 | '<='=11
29 | '<'=12
30 | 'isNull'=13
31 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/expected/ExpectedStepLexer.tokens:
--------------------------------------------------------------------------------
1 | T__0=1
2 | T__1=2
3 | NOT=3
4 | EQ=4
5 | REGEX=5
6 | CONTAINS=6
7 | BEGINS=7
8 | ENDS=8
9 | GREATER_THAN_OR_EQUALS=9
10 | GREATER_THAN=10
11 | LESS_THAN_OR_EQUALS=11
12 | LESS_THAN=12
13 | IS_NULL=13
14 | NUM=14
15 | BOOL=15
16 | WORD=16
17 | STRING=17
18 | SPACE=18
19 | 'Set'=1
20 | 'Export'=2
21 | '='=4
22 | '~'=5
23 | 'contains'=6
24 | 'beginsWith'=7
25 | 'endsWith'=8
26 | '>='=9
27 | '>'=10
28 | '<='=11
29 | '<'=12
30 | 'isNull'=13
31 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/expected/ParseGrammar - Expected.launch:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/keyvalue/KeyValue.g4:
--------------------------------------------------------------------------------
1 | grammar KeyValue;
2 |
3 | @header {
4 | package step.repositories.parser.keyvalue;
5 | }
6 |
7 | parse
8 | : keyValueList EOF
9 | ;
10 |
11 | keyValueList
12 | : keyValue*
13 | ;
14 |
15 | keyValue
16 | : key EQ value
17 | ;
18 |
19 | key : WORD|STRING;
20 |
21 | value : WORD|STRING|DYNAMIC_EXPRESSION;
22 |
23 | EQ : '=';
24 |
25 | WORD: (~[|=" \u00A0\t\r\n])+ ;
26 |
27 | STRING
28 | : '"' (~["\r\n] | '""')* '"'
29 | ;
30 |
31 | DYNAMIC_EXPRESSION
32 | : '|' (~[|] | '||')* '|'
33 | ;
34 |
35 | SPACE
36 | : [ \u00A0\t\r\n] -> skip
37 | ;
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/keyvalue/KeyValue.tokens:
--------------------------------------------------------------------------------
1 | EQ=1
2 | WORD=2
3 | STRING=3
4 | DYNAMIC_EXPRESSION=4
5 | SPACE=5
6 | '='=1
7 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/main/java/step/repositories/parser/keyvalue/KeyValueLexer.tokens:
--------------------------------------------------------------------------------
1 | EQ=1
2 | WORD=2
3 | STRING=3
4 | DYNAMIC_EXPRESSION=4
5 | SPACE=5
6 | '='=1
7 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/test/resources/step/plans/nl/parser/complexPlan.plan:
--------------------------------------------------------------------------------
1 | //For loop
2 | For 1 to 2
3 | //Call a keyword
4 | CallFunction
5 | //Assert - City equals Basel
6 | Assert City = "Basel"
7 | //BeforeSequence
8 | BeforeSequence
9 | //some echo in before sequence
10 | Echo "${counter}"
11 | //before sequence end
12 | End
13 | //some echo in iteration
14 | Echo "${counter}"
15 | //AfterSequence
16 | AfterSequence
17 | //some echo in afterSequence
18 | Echo "${counter}"
19 | //after sequence end
20 | End
21 | //After section
22 | After
23 | //some echo in after section
24 | Echo in after
25 | //After end
26 | End
27 | //some other echo in iteration
28 | Echo "${counter}"
29 | //For end
30 | End
31 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/test/resources/step/plans/nl/parser/test.plan:
--------------------------------------------------------------------------------
1 | For 1 to 10
2 | // My Echo
3 | // with some description
4 | Echo "Hello"
5 | End
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/test/resources/step/plans/nl/parser/testAssert.expected.txt:
--------------------------------------------------------------------------------
1 | TestCase:PASSED:
2 | Session:PASSED:
3 | CallKeyword:PASSED:
4 | Sequence:PASSED:
5 | Script:PASSED:
6 | Assert:PASSED:
7 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/test/resources/step/plans/nl/parser/testAssert.plan:
--------------------------------------------------------------------------------
1 | Function name="test1"
2 | Script output.add("Name",input.getString('Name'))
3 | EndFunction
4 |
5 | test1 Name="Franz"
6 | Assert Name="Franz"
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/test/resources/step/plans/nl/parser/testInnerFunctions.expected.txt:
--------------------------------------------------------------------------------
1 | TestCase:PASSED:
2 | Session:PASSED:
3 | Set:PASSED:
4 | CallKeyword:PASSED:
5 | Sequence:PASSED:
6 | CallKeyword:PASSED:
7 | Sequence:PASSED:
8 | CallKeyword:PASSED:
9 | Sequence:PASSED:
10 | Echo:PASSED:
11 |
--------------------------------------------------------------------------------
/step-plans/step-plans-parser/src/test/resources/step/plans/nl/parser/testInnerFunctions.plan:
--------------------------------------------------------------------------------
1 | Set var = "hallo"
2 |
3 | Function name="test2"
4 | test3 vorname = "Franz" Name = "${input.getString('Name')}"
5 |
6 | Function name="test3"
7 | Echo "$var ${input.getString('vorname')} ${input.getString('Name')}"
8 | EndFunction
9 | EndFunction
10 |
11 | Function name="test1"
12 | test2 Name = "${input.getString('Name')}"
13 | EndFunction
14 |
15 | test1 Name="Muster"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/YamlPlanConversionTool.run.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/agents/test-agents-configuration-yaml.yml:
--------------------------------------------------------------------------------
1 | version: 1.0.0
2 | name: "test plan"
3 | agents:
4 | - pool: "myPool"
5 | replicas: 1
6 | - pool: "myPool2"
7 | replicas: 2
8 | image: "test-image"
9 | root:
10 | sequence:
11 | children: []
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/benchmark/test-benchmark-sample-plan.yml:
--------------------------------------------------------------------------------
1 | version: 1.0.0
2 | name: "Performance assert example"
3 | root:
4 | testCase:
5 | children:
6 | - threadGroup:
7 | users: 1
8 | pacing: 0
9 | maxDuration: 0
10 | iterations: 10
11 | children:
12 | - callKeyword:
13 | keyword: "Buy MacBook in OpenCart"
14 | - performanceAssert:
15 | measurementName: "Buy MacBook in OpenCart"
16 | expectedValue: 10000
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/benchmark/test-converted-benchmark-sample-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "Performance assert example"
4 | root:
5 | testCase:
6 | nodeName: "Performance assert example"
7 | children:
8 | - threadGroup:
9 | children:
10 | - callKeyword:
11 | keyword: "Buy MacBook in OpenCart"
12 | iterations: 10
13 | pacing: 0
14 | after:
15 | continueOnError: false
16 | steps:
17 | - performanceAssert:
18 | measurementName: "Buy MacBook in OpenCart"
19 | expectedValue: 10000
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/call-plan/test-call-plan.yml:
--------------------------------------------------------------------------------
1 | name: "Plan1"
2 | root:
3 | testCase:
4 | nodeName: "Plan1"
5 | skipNode: false
6 | instrumentNode: false
7 | continueParentNodeExecutionOnError: false
8 | children:
9 | - callPlan:
10 | selectionAttributes:
11 | - name: "Plan2"
12 | input:
13 | - inputtest: "some other value"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/call-plan/test-converted-from-tech-call-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "Plan1"
4 | root:
5 | testCase:
6 | nodeName: "Plan1"
7 | children:
8 | - callPlan:
9 | selectionAttributes:
10 | - name: "Plan2"
11 | input:
12 | - inputtest: "some other value"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/check/test-check-plan.yml:
--------------------------------------------------------------------------------
1 | name: "test check artefact"
2 | root:
3 | sequence:
4 | name: Sequence
5 | children:
6 | - check:
7 | nodeName: Check
8 | expression: "'true'"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/check/test-converted-from-tech-check-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "test check artefact"
4 | root:
5 | sequence:
6 | nodeName: "test check artefact"
7 | children:
8 | - check:
9 | expression: "'true'"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/data-set/test-data-set-converted-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "test plan"
4 | root:
5 | sequence:
6 | nodeName: "test plan"
7 | children:
8 | - dataSet:
9 | description: "test excel"
10 | dataSource:
11 | excel:
12 | forWrite: true
13 | file:
14 | id: "644fbe4e38a61e07cc3a4df9"
15 | worksheet: "myWorksheet"
16 | headers: true
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/data-set/test-data-set-plan.yml:
--------------------------------------------------------------------------------
1 | name: "test plan"
2 | root:
3 | sequence:
4 | name: Sequence
5 | children:
6 | - dataSet:
7 | description: "test excel"
8 | dataSource:
9 | excel:
10 | file:
11 | id: "644fbe4e38a61e07cc3a4df9"
12 | headers: true
13 | worksheet: "myWorksheet"
14 | forWrite: true
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/editor/test-valid-source.yml:
--------------------------------------------------------------------------------
1 | version: "1.1.0"
2 | name: "myPlan"
3 | root:
4 | sequence:
5 | nodeName: "myPlan"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/for/test-for-converted-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "test plan"
4 | root:
5 | sequence:
6 | nodeName: "test plan"
7 | children:
8 | - for:
9 | description: "test for"
10 | item: "testCounter"
11 | maxFailedLoops: 3
12 | threads: 2
13 | globalCounter: "testGCounter"
14 | userItem: "testUserId"
15 | start: 10
16 | end: 20
17 | inc: 5
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/for/test-for-plan.yml:
--------------------------------------------------------------------------------
1 | name: "test plan"
2 | root:
3 | sequence:
4 | name: Sequence
5 | children:
6 | - for:
7 | description: "test for"
8 | start: 10
9 | end: 20
10 | inc: 5
11 | threads: 2
12 | maxFailedLoops: 3
13 | userItem: "testUserId"
14 | globalCounter: "testGCounter"
15 | item: "testCounter"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/function-group/test-function-group-converted-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "test plan"
4 | root:
5 | sequence:
6 | nodeName: "test plan"
7 | children:
8 | - session:
9 | routing:
10 | - criteria1: "criteriaValue1"
11 | - criteria2: "criteriaValue2"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/function-group/test-function-group-plan.yml:
--------------------------------------------------------------------------------
1 | name: "test plan"
2 | root:
3 | sequence:
4 | name: Sequence
5 | children:
6 | - session:
7 | nodeName: Session
8 | routing:
9 | - criteria1: "criteriaValue1"
10 | - criteria2: "criteriaValue2"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/invalid/test-invalid-plan-1.yml:
--------------------------------------------------------------------------------
1 | root:
2 | sequence:
3 | name: Sequence
4 | children:
5 | - if:
6 | nodeName: "IfBlock"
7 | condition: true
8 | description: "my description"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/invalid/test-invalid-plan-2.yml:
--------------------------------------------------------------------------------
1 | version: "1.0.0"
2 | name: "test plan"
3 | root:
4 | sequence:
5 | nodeName: Sequence
6 | children:
7 | - wrongArtefact:
8 | nodeName: "wrong"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/migration/test-migration-plan.yml:
--------------------------------------------------------------------------------
1 | version: "0.0.0"
2 | name: "test plan"
3 | root:
4 | oldSequence:
5 | nodeName: Sequence
6 | children:
7 | - oldAssert:
8 | nodeName: Assert
9 | oldOperator: "EQUALS"
10 | actual:
11 | expression: "'status'"
12 | expected: "ok"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/plaintext/plaintext-expected-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "converted plaintext plan"
4 | root:
5 | testCase:
6 | nodeName: "converted plaintext plan"
7 | children:
8 | - set:
9 | key: "key"
10 | value:
11 | expression: "\"value with space\""
12 | - set:
13 | key: "key2"
14 | value:
15 | expression: "\"value2\""
16 | - check:
17 | nodeName: "works"
18 | expression: "key2.toString().equals('value2')"
19 | - check:
20 | nodeName: "compile error"
21 | expression: "key2.toString().equals(\"value2\")"
22 | - check:
23 | nodeName: "compile error"
24 | expression: "key.toString().equals('value with space')"
25 | - check:
26 | expression: "key.toString().equals('value with space')"
27 | - callKeyword:
28 | children:
29 | - assert:
30 | actual: "isSendSuccess"
31 | operator: "EQUALS"
32 | expected:
33 | expression: "\"true\""
34 | keyword: "GroovyCheck"
35 |
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/plaintext/plaintext.plan:
--------------------------------------------------------------------------------
1 | Set key="value with space"
2 | Set key2="value2"
3 | //works
4 | Check Expression = key2.toString().equals('value2')
5 | //compile error
6 | Check key2.toString().equals("value2")
7 | //compile error
8 | Check key.toString().equals('value with space')
9 | Check Expression = |key.toString().equals('value with space')|
10 | GroovyCheck
11 | Assert isSendSuccess="true"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/return/test-return-converted-plan.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: "1.1.0"
3 | name: "Plan with return"
4 | root:
5 | sequence:
6 | nodeName: "Plan with return"
7 | children:
8 | - return:
9 | output:
10 | - output1: "value"
11 | - output2:
12 | expression: "'some thing dynamic'"
--------------------------------------------------------------------------------
/step-plans/step-plans-yaml-parser/src/test/resources/step/plans/parser/yaml/return/test-return-plan.yml:
--------------------------------------------------------------------------------
1 | name: "Plan with return"
2 | root:
3 | sequence:
4 | children:
5 | - return:
6 | output:
7 | - output1: "value"
8 | - output2:
9 | expression: "'some thing dynamic'"
--------------------------------------------------------------------------------
/step-repositories/step-repositories-artifact/.gitignore:
--------------------------------------------------------------------------------
1 | maven/
--------------------------------------------------------------------------------
/step-repositories/step-repositories-artifact/src/test/resources/step/repositories/artifact/plans-with-keywords.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-repositories/step-repositories-artifact/src/test/resources/step/repositories/artifact/plans-with-keywords.jar
--------------------------------------------------------------------------------
/step-repositories/step-repositories-artifact/src/test/resources/step/repositories/artifact/step-junit-tests-invalid.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-repositories/step-repositories-artifact/src/test/resources/step/repositories/artifact/step-junit-tests-invalid.jar
--------------------------------------------------------------------------------
/step-repositories/step-repositories-artifact/src/test/resources/step/repositories/artifact/step-junit-tests.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/exense/step/e4da4083b2fa165e0e93d1211c46ce40121d65f1/step-repositories/step-repositories-artifact/src/test/resources/step/repositories/artifact/step-junit-tests.jar
--------------------------------------------------------------------------------