eclipse-jkube / jkube

Build and Deploy java applications on Kubernetes
https://www.eclipse.dev/jkube/
Eclipse Public License 2.0
712 stars 464 forks source link

WatchServiceTest is failing on Windows #2968

Open rohanKanojia opened 3 months ago

rohanKanojia commented 3 months ago

Component

JKube Kit

Task description

Description

Originally posted by @Sintivrousai in Gitter Thread

It looks like WatchServiceTest is failing on Windows again. We had merged a fix https://github.com/eclipse-jkube/jkube/pull/2678 to fix this test but not sure why test has started failing again:

[ERROR] Failures:
[ERROR]   WatchServiceTest$Copy.callsPostExec:252
Expecting
  <CompletableFuture[Incomplete]>
to be completed within 5S.

Expected Behavior

WatchServiceTest should pass on windows

Acceptance Criteria

Sintivrousai commented 3 months ago

I'm a beginner but i would like to try resolve it.

Sintivrousai commented 1 month ago

Hello, as i was trying to see what's wrong with the test i noticed that sometimes it passed normally. I think maybe it has to do with if the docker desktop is open or not since the tests are for docker. If that's the case i could enable them only on linux or add this as a requirement?

rohanKanojia commented 1 month ago

@Sintivrousai : Could it be a timeout issue? Does test pass if you increase the timeout from 5 seconds to more?

Sintivrousai commented 1 month ago

That should be the case. I tried with 10sec and it passed.

rohanKanojia commented 1 month ago

@Sintivrousai : Hmm, I see. Does it pass everytime or it fails some time?

Sintivrousai commented 1 month ago

Not everytime apparently. I am testing with 20secs now and its okey so far. I am going to experiment it a little more.

Sintivrousai commented 1 month ago

I keep facing some problems and i have increased the time limits more than I expected (even to 3minutes). However, one good thing is that the fails has been reduced quite a bit. What i mean is that when i try to build it 2 times out of 3 it does not fail. I have changed the time empirically. It does not seem right to me to keep increasing the time.

rohanKanojia commented 1 month ago

@Sintivrousai : Maybe it's better to check what's causing wait in test execution and see if it's something related to windows. On Linux, the test passes normally

l3002 commented 3 weeks ago

Hi @Sintivrousai , @rohanKanojia : I'm unable to replicate this issue. Are we sure that the test is still failing?

vijaybhagwat24 commented 1 day ago

hi @rohanKanojia , took latest of master on local and ran the test cases: image

test method "callsPostExec" mentioned is passed but not the other two test methods: 1.buildImage() 2.customizesImage() are failing. May be we can close this and open another issue for those.