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

Fix SimpleCov Execution #771

Merged
merged 2 commits into from Jan 22, 2013

Conversation

Projects
None yet
6 participants
@parkr
Member

parkr commented Jan 21, 2013

Re: the discussion on 00d74fa, I have modified the way SimpleCov works so that it only runs when specified. To generate coverage, run rake test with COVERAGE=true.

(I tried a rake task, but couldn't get it to work with SimpleCov.)

CC: @mojombo, @mattr-, @tombell.

@parkr

This comment has been minimized.

Member

parkr commented Jan 21, 2013

On my machine, running just rake test produced the following time results:

Finished tests in 14.024888s, 11.9074 tests/s, 22.1749 assertions/s.

167 tests, 311 assertions, 0 failures, 0 errors, 0 skips

real    0m17.335s
user    0m7.665s
sys 0m1.072s

When running with COVERAGE=true, it took a bit longer:

Finished tests in 18.248353s, 9.1515 tests/s, 17.0426 assertions/s.

167 tests, 311 assertions, 0 failures, 0 errors, 0 skips
Coverage report generated for Unit Tests to /Users/parkermoore/code/jekyll-clean/coverage. 739 / 988 LOC (74.8%) covered.

real    0m22.429s
user    0m10.043s
sys 0m1.145s

It is interesting to see that running tests with SimpleCov is nearly 30% slower than running them without.

@tombell

This comment has been minimized.

Contributor

tombell commented Jan 21, 2013

👍

1 similar comment
@mattr-

This comment has been minimized.

Member

mattr- commented Jan 21, 2013

👍

@mojombo

This comment has been minimized.

Contributor

mojombo commented Jan 21, 2013

👍

parkr added a commit that referenced this pull request Jan 22, 2013

@parkr parkr merged commit 8d05e1e into master Jan 22, 2013

1 check passed

default The Travis build passed
Details

@parkr parkr deleted the fix-coverage branch Jan 22, 2013

parkr added a commit that referenced this pull request Jan 22, 2013

@Annalyn

This comment has been minimized.

Annalyn commented Jan 27, 2013

Hello, I don't know where to put this but I need help so badly :(
I deployed my Jekyll site on my server by just uploading all files and folders from the _site folder last night. When I wake up this morning, my desktop folders are all gone. How can I recover them? They contain very important files. Please.

@parkr

This comment has been minimized.

Member

parkr commented Jan 27, 2013

@Annalyn I'm sorry you're having these problems but I have no idea how to help you. Your _site folder and your Desktop should be separate folders.

@Annalyn

This comment has been minimized.

Annalyn commented Jan 27, 2013

Thanks parkr. I put my jekyll site folder on my desktop when I started building it and didn't bother to put it somewhere else. Well it's a working copy at least. I still have a copy of my _site on my user folder but some important files on my desktop are all gone. I can't find them on the Trash folder. I am totally new to Jekyll and using my Terminal and I installed a lot of stuff from these tutorials. I'm happy I have my Jekyll site up but loosing some important files is not good.

@parkr

This comment has been minimized.

Member

parkr commented Jan 27, 2013

Definitely not! Did any of these tutorials tell you to delete files? Is your jekyll folder within the desktop folder is it the desktop folder itself?

@Annalyn

This comment has been minimized.

Annalyn commented Jan 27, 2013

I didn't delete anything, it just that, my desktop is clean when I open my computer. Yup my jekyll is within the desktop folder. I have other folders (important) on my desktop.

@parkr

This comment has been minimized.

Member

parkr commented Jan 27, 2013

If you haven't deleted anything, I don't know why anything is gone. Jekyll only cleans out the _site folder. Unless that was pointed to the desktop, then Jekyll didn't do it. :-/

@Annalyn

This comment has been minimized.

Annalyn commented Jan 27, 2013

That happens on my first attempt and when I re-do it, the desktop folder cleans itself, maybe its the setting I did on my _configure.yml? what do you think? so when I upload _site folder on my server everything in that folder will be deleted?

@parkr

This comment has been minimized.

Member

parkr commented Jan 27, 2013

What's your _config.yml look like? When you upload, nothing should be deleted!

@Annalyn

This comment has been minimized.

Annalyn commented Jan 27, 2013

I don't know if this will work. I keep on changing my _config yml, since this morning. This is how it looks like now

auto: false
server: true
permalink: /
pygments: true

I think I give up. Lesson learned: i have to make sure that I seperate my jekyll folder or any other working folder I have to a separate folder. is the /Users folder advisable?

@parkr

This comment has been minimized.

Member

parkr commented Jan 27, 2013

That should be fine. The default working directory is ., or Dir.pwd in Ruby.

Yes, always keep your jekyll site in a subdirectory and keep everything in there.

@Annalyn

This comment has been minimized.

Annalyn commented Jan 27, 2013

Thanks for your patience @parkr . I have already build my site with Jekyll but I guess I need to learn more of Ruby to understand all of these? (silly question I know). So I just need to put that Dir.pwd on my _config.yml? I have tried Octopress and jekyllbootstrap before I started on bare jekyll and they all work just fine, but I want to learn how to do jekyll from scratch. Now I lost my portfolio folder and workspace folder that includes my client's website pre dev files.

@parkr

This comment has been minimized.

Member

parkr commented Jan 27, 2013

Yikes! I'm sorry to hear that. I hope you backed them up before this :-/

Nope, just put source: "." in your _config.yml. It's the default, though, so it shouldn't make a difference. You might care more about destination, though. The default is _site, but if you replaced that with ., for example, it will clean out your current directory, which is definitely not a good thing.

@Annalyn

This comment has been minimized.

Annalyn commented Jan 27, 2013

I know. Well luckily I have the other folders on my download and I created on of my project a Github repo. Thanks I will keep that in mind. Thanks for your help @parkr , I appreciate it.

@parkr

This comment has been minimized.

Member

parkr commented Jan 27, 2013

You bet! Best of luck in the future.

@jekyll jekyll locked and limited conversation to collaborators Feb 27, 2017

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.