-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test case to verify delta to a running supervisor #43
Conversation
Device "${device_uuid}" log should not contain "Killing application" | ||
Change output console with "Grettings world!" | ||
Wait Until Keyword Succeeds 30x 10s Device "${device_uuid}" log should contain "Grettings world!" | ||
Check if value of ENV variable is "1" in application "${application_name}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems to be missing "RESIN_SUPERVISOR_DELTA" here.
${result} = Run Process echo "${result_env.stdout}" | grep ${variable_name} | grep " ${variable_value}" shell=yes | ||
Process ${result} | ||
|
||
Remove ENV variable "${variable_name}" with value "${variable_value}" from application "${application_name}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While removing a variable its value does not seem to be relevant.
Process ${result_id} | ||
${result} = Run Process resin env rm ${result_id.stdout} --yes shell=yes | ||
Process ${result} | ||
|
||
Push output console with "${message}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This keyword assumes that the git_url push has been done above - In order to keep this independent of that - maybe we can do a fresh clone in a separate directory and git push from there. My rationale is that we should either capture dependencies properly or the keyword should be independent of most previous keywords / states. Thoughts?
# ${result} = Run Process git push resin ${commit_hash}:refs/heads/master shell=yes cwd=/tmp/${application_name} | ||
# Process ${result} | ||
|
||
Get "${git_url}" to "${directory}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GIT CLONE as a keywork itself - so that the similar semantics are maintained?
GIT CLONE ${git_url} ${directory}
${result} = Run Process git clone ${git_url} ${directory} shell=yes | ||
Process ${result} | ||
|
||
Push "${commit_hash}" to application "${application_name}" from "${directory}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about
GIT PUSH "${directory}:${commit_hash}" to application "${application_name}"
Process ${result} | ||
|
||
Git pushing to application "${application_name}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We shouldnt be assuming application_repo - they should all be taken as inputs when the keyword is called - The keyword in the current form will assume that somewhere application _repo is set and uses it - the test suit will not be explicitly stating this when calling the keyword, leading to confusion.
Git pushing to application | ||
Push "${application_repo}":"${application_commit}" to application "${application_name}" | ||
Push "${application_repo}":"${application_commit}" to application "${application_name}" from "/tmp/${application_name}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lets remove this key word all together and use the containing parts
i.e two lines 1) Git clone 2) git push
Remove ENV variable "autohat${random}" from application "${application_name}" | ||
|
||
Check delta to a running supervisor on "${application_name}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about - Check enabling supervisor delta on ?
Remove ENV variable "RESIN_SUPERVISOR_DELTA" from application "${application_name}" | ||
[Teardown] Run Keyword Remove Directory /tmp/${random} recursive=True | ||
|
||
Add output console "${message}" to "${directory}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add console output
Check if resin sync works | ||
Check if resin sync works on "${device_uuid}" | ||
Check if setting environment variable works | ||
Check if setting environment variables works on "${application_name}" | ||
Verify if host OS version of the image is same through resin cli | ||
Check if host OS version of device "${device_uuid}" is "${os_version}" | ||
Wait till Qemu is killed or 30 seconds |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missed this - We need to call a device shutdown before waiting for the process to exit - right now the timeout will always occur and the qemu instance will be killed
resin device shutdown
command could be incorporated in resincli.robot and used here
Signed-off-by: horia-delicoti <[email protected]>
…fter killing qemu instance Signed-off-by: horia-delicoti <[email protected]>
…ed on application Signed-off-by: horia-delicoti <[email protected]>
Signed-off-by: horia-delicoti <[email protected]>
Signed-off-by: horia-delicoti <[email protected]>
Signed-off-by: horia-delicoti <[email protected]>
Signed-off-by: horia-delicoti <[email protected]>
Signed-off-by: horia-delicoti <[email protected]>
@lifeeth @villaseca
Connects to #31