Skip to content
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

Fixes watch test #2895

Merged
merged 1 commit into from Apr 17, 2020
Merged

Fixes watch test #2895

merged 1 commit into from Apr 17, 2020

Conversation

mik-dass
Copy link
Contributor

@mik-dass mik-dass commented Apr 16, 2020

What type of PR is this?

/kind bug
/kind cleanup
/kind flake

What does does this PR do / why we need it:

This fixes the watch test for mac. Also refactors the devfile watch test.

Which issue(s) this PR fixes:

Fixes #2570

How to test changes / Special notes to the reviewer:

  • make test should pass on mac (run at least 50-100 times)

@openshift-ci-robot openshift-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. Required by Prow. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. Required by Prow. labels Apr 16, 2020
@openshift-ci-robot openshift-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. Required by Prow. label Apr 16, 2020
@mik-dass mik-dass force-pushed the watch_fix_mac branch 4 times, most recently from 7aacb57 to ebceb54 Compare April 16, 2020 09:23
@openshift-ci-robot openshift-ci-robot added kind/bug Categorizes issue or PR as related to a bug. kind/cleanup flake Categorizes issue or PR as related to a flaky test. labels Apr 16, 2020
@mik-dass mik-dass changed the title [WIP] Fixes watch test Fixes watch test Apr 16, 2020
@openshift-ci-robot openshift-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. Required by Prow. label Apr 16, 2020
@mik-dass mik-dass requested review from kadel, prietyc123 and amitkrout and removed request for mohammedzee1000 and maysunfaisal April 16, 2020 09:40
@girishramnani
Copy link
Contributor

Can you please share how was this solved and what was the issue?

@amitkrout
Copy link
Contributor

prow issue
/retest

@mik-dass
Copy link
Contributor Author

Can you please share how was this solved and what was the issue?

The test setup uses ioutil for creating temp directories and folders. Thus all the files and folders have a random string attached to the end of their path.

We use a glob expression tests/ for ignoring the tests folder. But because of the above reason, the folder is never ignored. So it was converted to tests*/.

Also we need to convert the glob expressions to their absolute forms for the watch function to work properly.

@amitkrout
Copy link
Contributor

prow issue
/retest

Copy link
Contributor

@amitkrout amitkrout left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested 100 time om macOS and all the execution went fine.

$ for i in $(seq 1 100); do echo $i && go test /Users/amit/go/src/github.com/openshift/odo/pkg/watch/watch.go /Users/amit/go/src/github.com/openshift/odo/pkg/watch/watch_test.go -p 1 -count=1; done
1
ok      command-line-arguments  21.104s
2
ok      command-line-arguments  23.094s
3
ok      command-line-arguments  21.103s
4
ok      command-line-arguments  22.104s
5
ok      command-line-arguments  22.104s
6
ok      command-line-arguments  21.121s
7
ok      command-line-arguments  25.100s
8
ok      command-line-arguments  23.124s
9
ok      command-line-arguments  27.118s
10
ok      command-line-arguments  24.108s
[...]
90
ok      command-line-arguments  24.117s
91
ok      command-line-arguments  23.112s
92
ok      command-line-arguments  22.100s
93
ok      command-line-arguments  24.101s
94
ok      command-line-arguments  22.097s
95
ok      command-line-arguments  24.095s
96
ok      command-line-arguments  21.109s
97
ok      command-line-arguments  20.105s
98
ok      command-line-arguments  22.105s
99
ok      command-line-arguments  23.102s
100
ok      command-line-arguments  27.107s

In the morning me and @mik-dass was working on the issue. So i understand the changes he has made.
/lgtm

@openshift-ci-robot openshift-ci-robot added the lgtm Indicates that a PR is ready to be merged. Required by Prow. label Apr 16, 2020
@kadel
Copy link
Member

kadel commented Apr 16, 2020

/approve

@openshift-ci-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: kadel

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. Required by Prow. label Apr 16, 2020
@prietyc123
Copy link
Contributor

I have also tested 100 time on macOS and all the execution passed. 👍

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

10 similar comments
@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@openshift-bot
Copy link

/retest

Please review the full test history for this PR and help us cut down flakes.

@codecov
Copy link

codecov bot commented Apr 17, 2020

Codecov Report

Merging #2895 into master will increase coverage by 0.03%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2895      +/-   ##
==========================================
+ Coverage   43.70%   43.73%   +0.03%     
==========================================
  Files         102      102              
  Lines        9160     9160              
==========================================
+ Hits         4003     4006       +3     
+ Misses       4780     4778       -2     
+ Partials      377      376       -1     
Impacted Files Coverage Δ
pkg/watch/watch.go 65.29% <0.00%> (+1.76%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 22a6364...486b29b. Read the comment docs.

@amitkrout
Copy link
Contributor

/refresh

@amitkrout amitkrout merged commit 96d4c0f into redhat-developer:master Apr 17, 2020
@openshift-ci-robot
Copy link
Collaborator

@mik-dass: The following tests failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/prow/v4.3-integration-e2e-benchmark 486b29b link /test v4.3-integration-e2e-benchmark
ci/prow/v4.2-integration-e2e-benchmark 486b29b link /test v4.2-integration-e2e-benchmark

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@mik-dass mik-dass deleted the watch_fix_mac branch May 5, 2020 03:20
@rm3l rm3l added the area/refactoring Issues or PRs related to code refactoring label Jun 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. Required by Prow. area/refactoring Issues or PRs related to code refactoring flake Categorizes issue or PR as related to a flaky test. kind/bug Categorizes issue or PR as related to a bug. lgtm Indicates that a PR is ready to be merged. Required by Prow.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FLAKE]make test fails on osx and windows in travis CI
8 participants