mem_commit | R Documentation |
Given a test-file's path, checks its memory metrics against the commit
specified by the commit object
passed as a parameter. Memory
metrics returned are the memory leaked and maximum memory utilized during
its execution.
mem_commit(test_path, test_commit)
test_path |
File-path for the test file which is to be checked. |
test_commit |
git2r commit |
mem_commit returns an object of class "data.frame".
The data-frame consists of the following columns:
test_name
metric_name
status
metric_val
message
sha
date_time
Function assumes the current directory to be the root directory of the package being tested.
commits
## Not run: ## Example-1 # Set the current directory to the git repository concerned. setwd("./Path/to/repository") # Obtain the commit object commit_list <- git2r::commits() t_commit <- commit_list[[1]] # Specify the test-file path t_path <- "Path/to/file" # Pass the parameters and obtain the memory stats library(Rperform) mem_commit(t_path, t_commit) ## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.