Skip to content

Conversation

@Kami
Copy link
Member

@Kami Kami commented Apr 8, 2019

This pull request fixes an issue introduced in #150 which I described here - #150 (comment).

tests pack is only used for end to end and st2-self-check script tests. As such, all the actions inside that pack should follow that action format.

To fix the issue, I made the following changes:

  1. Moved new action inside fixtures pack - that's where "fixture" actions should live
  2. Added new tests.test_render_config_context action which uses the fixture action and tests render config context functionality

This will also require changed in StackStorm/st2 repo. We can likely get rid of all the "clone st2tests" pack change from this PR - StackStorm/st2#4567.

@Kami
Copy link
Member Author

Kami commented Apr 8, 2019

Confirmed it's working:

Deleting 'st2tests' directory from /home/ubuntu.
~
Attempting Test tests.test_inquiry_chain...OK! (47s)
Attempting Test tests.test_inquiry_mistral...OK! (49s)
Attempting Test tests.test_key_triggers...OK! (33s)
Attempting Test tests.test_pack_install_tool...OK! (10s)
Attempting Test tests.test_packs_pack...OK! (76s)
Attempting Test tests.test_quickstart...OK! (21s)
Attempting Test tests.test_quickstart_key...OK! (6s)
Attempting Test tests.test_quickstart_local_script_actions...OK! (13s)
Attempting Test tests.test_quickstart_passive_sensor...OK! (7s)
Attempting Test tests.test_quickstart_polling_sensor...OK! (4s)
Attempting Test tests.test_quickstart_python_actions...OK! (11s)
Attempting Test tests.test_quickstart_remote_script_actions...OK! (14s)
Attempting Test tests.test_quickstart_rules...OK! (62s)
Attempting Test tests.test_quickstart_trace...OK! (16s)
Attempting Test tests.test_render_config_context...OK! (5s)

@Kami Kami added this to the 3.0.0 milestone Apr 8, 2019
@jinpingh
Copy link
Contributor

jinpingh commented Apr 8, 2019

@Kami Not sure how it is working for moving packs/tests/actions/render_config_context.py → packs/fixtures/render_config_context.py
Should it be moved under packs/fixtures/actions directory?

If action is moved to fixtures pack, it will break https://github.com/StackStorm/st2/blob/master/st2tests/integration/orquesta/test_wiring.py integration test case test_config_context_renders. https://github.com/StackStorm/st2/blob/master/contrib/examples/actions/workflows/render_config_context.yaml and https://github.com/StackStorm/st2/blob/master/tools/launchdev.sh need to be changed.

@Kami
Copy link
Member Author

Kami commented Apr 8, 2019

@Kami Not sure how it is working for moving packs/tests/actions/render_config_context.py → packs/fixtures/render_config_context.py
Should it be moved under packs/fixtures/actions directory?

Yeah, I've fixed that locally already, but haven't pushed the changes yet - I've pushed them now.

I will look into the StackStorm/st2 change - one option would be to simply move that action to the examples pack (IIRC, we already have a similar action there).

@Kami
Copy link
Member Author

Kami commented Apr 8, 2019

I've pushed latest changes.

Per our discussion on Slack, I moved action to fixtures pack StackStorm/st2#4625.

@Kami Kami merged commit 4f156e2 into master Apr 9, 2019
@Kami Kami deleted the fix_broken_action branch April 9, 2019 08:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants