Here's an example of how to debug Mocha v4 if it hangs.
Ensure you're using a Node.js 8 or newer (or any version with async_hooks support).
If you run your test, you'll notice it hangs:
$ mocha test.js
Here's an example of how to debug Mocha v4 if it hangs.
Ensure you're using a Node.js 8 or newer (or any version with async_hooks support).
If you run your test, you'll notice it hangs:
$ mocha test.js
import Foundation | |
import Eureka // https://github.com/xmartlabs/Eureka | |
public extension Form { | |
public func valuesForFirebase(includeHidden: Bool = false) -> [String: Any?] { | |
let rows = includeHidden ? self.allRows : self.rows | |
return rows.filter({ $0.tag != nil }) | |
.reduce([:], { (dictionary, row) -> [String: Any?] in | |
var dictionary = dictionary | |
dictionary[row.tag!] = row.firebaseValue |
- (BOOL)openTwitterClientForUserName:(NSString*)userName { | |
NSArray *urls = [NSArray arrayWithObjects: | |
@"twitter:@{username}", // Twitter | |
@"tweetbot:///user_profile/{username}", // TweetBot | |
@"echofon:///user_timeline?{username}", // Echofon | |
@"twit:///user?screen_name={username}", // Twittelator Pro | |
@"x-seesmic://twitter_profile?twitter_screen_name={username}", // Seesmic | |
@"x-birdfeed://user?screen_name={username}", // Birdfeed | |
@"tweetings:///user?screen_name={username}", // Tweetings | |
@"simplytweet:?link=http://twitter.com/{username}", // SimplyTweet |
#!/usr/bin/env ruby | |
# this will let you download the original files | |
# from a premium dropio drop | |
# run it in the command line with "ruby fetch_original_dropio_files.rb" | |
require 'rubygems' | |
require 'fileutils' | |
require 'httparty' |
#!/usr/bin/env ruby | |
puts "looking for the gems to upgrade..." | |
gem_info = Struct.new(:name, :version) | |
to_reinstall = [] | |
Dir.glob('/Library/Ruby/Gems/**/*.bundle').map do |path| | |
path =~ /.*1.8\/gems\/(.*)-(.*?)\/.*/ | |
name, version = $1, $2 | |
bundle_info = `file path` | |
to_reinstall << gem_info.new(name, version) unless bundle_info =~ /bundle x86_64/ | |
end |