oyencov 0.0.13 → 0.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0ba9c476e48efe6793999e48c4e278283b1522ec5f277e986639de5350763c9e
4
- data.tar.gz: 86fcd80181d4d7f37e0c23d33f75332c2c79d91d36ba559af4b4e287865e19c4
3
+ metadata.gz: 56fb7dec01c127b50a2af690eefcd419cc7d86d4c41c432d562550990bbfd66c
4
+ data.tar.gz: 3ba9a297ab176fa1481a4db7a560573efa54787ae779392188b95ff6accef759
5
5
  SHA512:
6
- metadata.gz: 9dbcadce821a07c21d77e8890d8a8a9cbe0e9c188520cbbb46d460c1f0586a3a5bdaf04db4de4556d0b409a02f83aecf7ec092e41289c18e92465341888dce50
7
- data.tar.gz: 3d04d1e9074385d5c4bea1d4e6c5c3c54061cf13919220a7f0a6a43a17fe62862cfbc04f75c413693b3a4b936522cd468f032d32c50b6ff31cf44a3e3381e363
6
+ metadata.gz: 6d3ec6bf338ad3977ac108a7cc5b567c2f3ff22bb601f62af87416561022e4b08eb6c67a1466dcc7b0a77e907c6836885e3429f854e51f72625f3b5932eaada5
7
+ data.tar.gz: a3fc843485093188f54c72b36156650d0e0b8a911a4a93d4961be4aa270a8f80d8738ffa89d577a8cac386d533afc4287b16c9a58bc333046786e60087eb0758
@@ -17,9 +17,9 @@ require_relative "logger"
17
17
  #
18
18
  module OyenCov
19
19
  class Background
20
- # Added to be more fork-aware. Ruby/Puma can fork a process copy-on-write,
20
+ # Added to be more fork-aware. Ruby/Puma can fork a process copy-on-write,
21
21
  # but it won't start the threads that are running in the parent process.
22
- #
22
+ #
23
23
  # If the PID > 0 but also not the current process_id, make the thread run.
24
24
  @@running_pid = 0
25
25
 
@@ -24,8 +24,8 @@ module OyenCov
24
24
  #
25
25
  # @return [Hash<String, >] Hash of methods to their children starting line count. The line count can be used to read how often the method is executed from `Coverage.peek_result`
26
26
  private_class_method def self.parse_file(filepath)
27
- traverse_ast(Parser::CurrentRuby.parse(File.read(filepath)))
28
- .reverse
27
+ ast = traverse_ast(Parser::CurrentRuby.parse(File.read(filepath))) || []
28
+ ast.reverse
29
29
  .to_h
30
30
  .select do |k, v|
31
31
  /\.|\#/.match?(k)
@@ -1,3 +1,3 @@
1
1
  module OyenCov
2
- VERSION = "0.0.13".freeze
2
+ VERSION = "0.0.14".freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: oyencov
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.13
4
+ version: 0.0.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anonoz Chong
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-07-03 00:00:00.000000000 Z
11
+ date: 2024-07-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday