Coveralls logob
Coveralls logo
  • Home
  • Features
  • Pricing
  • Docs
  • Sign In

abs-lang / abs
73%
master: 76%

DEFAULT BRANCH: master
Build:
LAST BUILD BRANCH: go-116
Repo Added 31 Jan 2019 09:07PM UTC
Total Files 7
# Builds 1432 Last
Badge
Badge Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH background-commands
branch: background-commands
CHANGE BRANCH
x
Reset
  • background-commands
  • badges
  • 1.1.x
  • make-hashes-iterable
  • destructuring-hashes
  • issue-144-cd-only
  • key-in-hash
  • sleep
  • contributing
  • release-1.1.0
  • 1.1.0
  • master
  • 1.2.x
  • issue-144-v2
  • issue-166
  • issue-164
  • issue-164-v2
  • parse-exponential-notation
  • absrc-source-file
  • issue-171
  • issue-171-alex
  • mount-abs-history-in-dev
  • better-illegal-tokens-when-parsing-numbers
  • number-math-rounding
  • issue-190
  • doc-command-executor
  • add-code-of-conduct-1
  • 1.2.0
  • 1.3.x
  • bats-testing
  • go-1.12
  • unicode
  • issue-199-exec
  • 1.3.0
  • 1.4.x
  • underscores-in-numeric-literals
  • go-mod
  • hash-str-should-convert-to-valid-json
  • implicit-return-value
  • fix-hash-to-json
  • 1.3.1
  • benchmark-for-lazy-evaluation
  • lazy-evaluation-in-1.3.x
  • 1.3.2
  • repl-without-terminal-no-panic
  • eval
  • allow-digits-in-vars
  • 1.4.0
  • 1.5.x
  • negate-in
  • 1.4.1
  • break-continue
  • higher-file-writers
  • stack-overflow
  • unique
  • 1.5.0
  • numeric-bash-arguments-support
  • 1.6.x
  • 1.5.1
  • deprecate-legacy-command-syntax
  • index-ranges
  • 1.6.0
  • 1.7.x
  • return-semicolon
  • 1.6.1
  • playground
  • reverse-search
  • echo-dying-message
  • reverse-search-2
  • replace-array
  • replace-short-form
  • number-abbr
  • index-ranges-bug
  • 1.6.2
  • 1.7.0
  • 1.8.x
  • source-vs-require
  • negative-indexes
  • bash-style-interpolation-in-strings
  • go-prompt-master
  • array-tsv
  • go-1.13
  • abs-installer-fixes
  • 1.8.0
  • 1.9.x
  • issue-284
  • 1.8.1
  • optional-chaining
  • arg-panic
  • 1.8.2
  • 1.8.3
  • 1.10.x
  • 1.10.0
  • 1.11.x
  • dependabot/bundler/docs/rubyzip-2.2.0
  • issue-303
  • issue-315
  • 1.10.1
  • named-functions
  • decorators
  • fn-call
  • 1.11.0
  • fix-324
  • 1.11.1
  • dependabot/bundler/docs/nokogiri-1.10.8
  • 1.11.2
  • embedded-interpolation
  • 1.11.3
  • multiple-decorators
  • 1.11.4
  • simplified-installer
  • 1.12.x
  • builtin-functions-tests
  • fn-chunk
  • fn-clamp
  • fn-between
  • upgraded-deps
  • funny-cases
  • find-shortcut
  • array-intersect
  • array-diff
  • symmetric-diff
  • array-union
  • array-flatten
  • array-flatten-deep
  • array-max
  • array-min
  • array-reduce
  • array-partition
  • 1.12.0
  • 1.13.x
  • std-library
  • fix-mixing-property-and-index-expression
  • 1.12.1
  • 2.0.x
  • deprecations
  • upgrade-guide
  • index-range-panics
  • 2.0.0
  • 2.1.x
  • descending-int-range
  • default-args-for-functions
  • 2.2.x
  • 2.1.0
  • cli-repl
  • write-outer-scope
  • memoize
  • 2.2.0
  • 2.3.x
  • fix-tests
  • memo-fix
  • 2.2.1
  • fix-negative-precedence
  • 2.2.2
  • bye-bye-darwin-386
  • go-1.15
  • 2.3.0
  • 2.4.x
  • edge-case-silent-return
  • 2.3.1
  • array-shuffle
  • reverse-copy
  • 2.5.x
  • 2.4.0
  • go-116

18 Feb 2019 - 5:32 coverage decreased (-0.4%) to 73.187%
401

Pull #179

travis-ci-com

9181eb84f9c35729a3bad740fb7f9d93?size=18&default=identiconweb-flow
Experimental support for background commands, closes #70

This was easier than I though, but it required some changes here
and there.

The `String` object now has an internal mutex, used to keep hold of
the value of the command until it's executed.

What really changed is that:

* regular commands go through "normally"
* background commands are defined as commands that end with `&` (`$(sleep 1 &)`)
* background commands are launched in a goroutine and "locked" with the above mutex
* when the command is over, we set its output and release the mutex
* added the `cmd.wait()` function which will try to acquire the lock on the mutex, thus waiting until the command is done
* added the `.done` property on string to understand whether a command is done or not

Fun things that we can do now:

```
cmd = `sleep 10`
echo("This will be printed in 10s")

cmd = `sleep 10 &`
echo("This will be printed immediately")
sleep(9000)
cmd.done # FALSE
cmd.ok # FALSE
echo("We have been waiting 9s")
cmd.wait()
echo("And approximately another second")
cmd.done # TRUE
cmd.ok # TRUE
```

@ntwrick hat do you think?
Pull Request #179: Experimental support for background commands, closes #70

60 of 98 new or added lines in 3 files covered. (61.22%)

328 existing lines in 4 files now uncovered.

2462 of 3364 relevant lines covered (73.19%)

78.68 hits per line

Relevant lines Covered
3364 RELEVANT LINES 2462 COVERED LINES
Build:
78.68 HITS PER LINE
Source Files on background-commands
  • Tree
  • List 14
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line

Recent Builds

Builds Branch Coverage Commit Committer Type Time Via
401 background-commands
73.19
Experimental support for background commands, closes #70 This was easier than I though, but it required some changes here and there. The `String` object now has an internal mutex, used to keep hold of the value of the command until it's executed... 9181eb84f9c35729a3bad740fb7f9d93?size=18&default=identiconweb-flow Pull #179 18 Feb 2019 05:49AM UTC travis-ci-com
400 background-commands
72.73
Experimental support for background commands, closes #70 This was easier than I though, but it required some changes here and there. The `String` object now has an internal mutex, used to keep hold of the value of the command until it's executed... 7e1b44a243d0cd4a01e5de1fa41fc0ed?size=18&default=identiconodino push 18 Feb 2019 05:47AM UTC travis-ci-com
394 background-commands
73.19
Experimental support for background commands, closes #70 This was easier than I though, but it required some changes here and there. The `String` object now has an internal mutex, used to keep hold of the value of the command until it's executed... 9181eb84f9c35729a3bad740fb7f9d93?size=18&default=identiconweb-flow Pull #179 18 Feb 2019 05:33AM UTC travis-ci-com
393 background-commands
73.19
Experimental support for background commands, closes #70 This was easier than I though, but it required some changes here and there. The `String` object now has an internal mutex, used to keep hold of the value of the command until it's executed... 7e1b44a243d0cd4a01e5de1fa41fc0ed?size=18&default=identiconodino push 18 Feb 2019 05:31AM UTC travis-ci-com
392 background-commands
73.19
Experimental support for background commands, closes #70 This was easier than I though, but it required some changes here and there. The `String` object now has an internal mutex, used to keep hold of the value of the command until it's executed... 9181eb84f9c35729a3bad740fb7f9d93?size=18&default=identiconweb-flow Pull #179 18 Feb 2019 05:28AM UTC travis-ci-com
See All Builds (1432)
  • Repo on GitHub
Troubleshooting · Open an Issue · Sales · Support · ENTERPRISE · CAREERS · STATUS
BLOG · TWITTER · Legal & Privacy · Supported CI Services · What's a CI service? · Automated Testing

© 2021 Coveralls, Inc