Module: SimpleCov::LastRun

### Home Classes Methods

### In Files

- lib/simplecov/last_run.rb

### Methods

- ::last_run_path
- ::read
- ::write

### Class/Module Index

Quicksearch

- SimpleCov
- SimpleCov::ArrayFilter
- SimpleCov::ArrayMergeHelper
- SimpleCov::BlockFilter
- SimpleCov::CommandGuesser
- SimpleCov::Configuration
- SimpleCov::ExitCodes
- SimpleCov::FileList
- SimpleCov::Filter
- SimpleCov::Formatter
- SimpleCov::Formatter::MultiFormatter
- SimpleCov::Formatter::SimpleFormatter
- SimpleCov::HashMergeHelper
- SimpleCov::LastRun
- SimpleCov::Profiles
- SimpleCov::Railtie
- SimpleCov::Result
- SimpleCov::ResultMerger
- SimpleCov::SourceFile
- SimpleCov::SourceFile::Line
- SimpleCov::StringFilter
- SimpleCov::VERSION
- Coverage

No matching classes.

# SimpleCov::LastRun

### Public Class Methods

last_run_path() click to toggle source

    # File lib/simplecov/last_run.rb, line 6
    def last_run_path
      File.join(SimpleCov.coverage_path, ".last_run.json")
    end

read() click to toggle source

    # File lib/simplecov/last_run.rb, line 10
    def read
      return nil unless File.exist?(last_run_path)
      JSON.parse(File.read(last_run_path))
    end

write(json) click to toggle source

    # File lib/simplecov/last_run.rb, line 15
    def write(json)
      File.open(last_run_path, "w+") do |f|
        f.puts JSON.pretty_generate(json)
      end
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.