Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename Coveralls.submit_token to submit_local #184

Merged
merged 3 commits into from
Oct 26, 2018
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/codecovio.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export Codecov
Coverage.Codecov Module

This module provides functionality to push coverage information to the CodeCov.io
web service. It exports the `submit` and `submit_token` methods.
web service. It exports the `submit` and `submit_local` methods.
"""
module Codecov
using HTTP
Expand Down
14 changes: 9 additions & 5 deletions src/coveralls.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export Coveralls
Coverage.Coveralls Module

This module provides functionality to push coverage information to the Coveralls
web service. It exports the `submit` and `submit_token` methods.
web service. It exports the `submit` and `submit_local` methods.
"""
module Coveralls
using Coverage
Expand All @@ -14,7 +14,7 @@ module Coveralls
using Compat.LibGit2
using MbedTLS

export submit, submit_token
export submit, submit_token, submit_local

#=
JSON structure for Coveralls
Expand Down Expand Up @@ -54,7 +54,7 @@ module Coveralls

Take a vector of file coverage results (produced by `process_folder`),
and submits them to Coveralls. Assumes that this code is being run
on TravisCI or AppVeyor. If running locally, use `submit_token`.
on TravisCI or AppVeyor. If running locally, use `submit_local`.
"""
function submit(fcs::Vector{FileCoverage}; kwargs...)
verbose = true
Expand Down Expand Up @@ -156,14 +156,15 @@ module Coveralls
end

"""
submit_token(fcs::Vector{FileCoverage}, git_info=query_git_info; kwargs...)
submit_local(fcs::Vector{FileCoverage}, git_info=query_git_info; kwargs...)

Take a `Vector` of file coverage results (produced by `process_folder`),
and submits them to Coveralls. For submissions not from TravisCI.

git_info can be either a `Dict` or a function that returns a `Dict`.
"""
function submit_token(fcs::Vector{FileCoverage}, git_info=query_git_info; kwargs...)

simonbyrne marked this conversation as resolved.
Show resolved Hide resolved
function submit_local(fcs::Vector{FileCoverage}, git_info=query_git_info; kwargs...)
data = Dict("repo_token" => get(ENV,"COVERALLS_TOKEN") do
get(ENV, "REPO_TOKEN") do #backward compatibility
error("Coveralls submission requires a COVERALLS_TOKEN environment variable")
Expand Down Expand Up @@ -195,4 +196,7 @@ module Coveralls
println(String(r.body))
end
end

@deprecate submit_token submit_local
ararslan marked this conversation as resolved.
Show resolved Hide resolved

end # module Coveralls