-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
65c6529
commit 4133222
Showing
10 changed files
with
20 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,4 +4,5 @@ pause | |
self process terminate. | ||
self process: nil. | ||
]. | ||
self paused: true. | ||
self paused: true. | ||
self updateStatus |
5 changes: 3 additions & 2 deletions
5
packages/AutoTDD-Core.package/ATDDTravisStatus.class/instance/resume.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
accessing | ||
resume | ||
self process | ||
self process | ||
ifNil: [self process: self startNewRefreshProcess]. | ||
self paused: false. | ||
self paused: false. | ||
self updateStatus. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
packages/AutoTDD-Core.package/TCIRepository.class/instance/clearCache.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
utility | ||
clearCache | ||
self cache: nil | ||
self cache: nil. | ||
self cache at: #lastRefresh put: TimeStamp now asTime asSeconds |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
9 changes: 5 additions & 4 deletions
9
packages/AutoTDD-Tests.package/ATDDTravisStatusTest.class/instance/testPauseResumeRun.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,20 @@ | ||
as yet unclassified | ||
testPauseResumeRun | ||
| travisStatus | | ||
| travisStatus time | | ||
travisStatus := ATDDTravisStatus new. | ||
travisStatus repositoryURL: self repoURL. | ||
|
||
self assert: (travisStatus asString isKindOf: String). | ||
self assert: (travisStatus asStringOrText isKindOf: Text). | ||
self assert: travisStatus paused. | ||
self assert: travisStatus repository cache keys size > 0. "the cache should not be empty because we just requested the status (by calling asString)" | ||
self assert: travisStatus repository cache keys size > 1. "the cache should not be empty because we just requested the status (by calling asString)" | ||
|
||
time := TimeStamp now asTime asSeconds. | ||
travisStatus refreshInterval: (Time hour: 0 minute: 0 second: 1 ) asSeconds. | ||
travisStatus resume. | ||
|
||
(Delay forSeconds: 2) wait. | ||
self assert: travisStatus paused not. | ||
self assert: travisStatus repository cache keys size = 0. "the automatic refreshing should have cleared the cache after 1 seconds" | ||
self assert: (travisStatus repository cache at: #lastRefresh) > time. | ||
|
||
travisStatus pause. | ||
self assert: travisStatus paused. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.