{"action":"created","comment":{"url":"https://api.github.com/repos/fastlane/frameit/pulls/comments/54793015","id":54793015,"diff_hunk":"@@ -0,0 +1,81 @@\n+describe Frameit do\n+  describe Frameit::Editor do\n+    context 'fonts' do\n+      def fake_screenshot(language)\n+        default_size = Frameit::Editor::FONT_SIZE_REFERENCE_WIDTH\n+        OpenStruct.new({\n+          path: \"fastlane/#{language}sometitle.png\",\n+          size: [default_size, -1],\n+        })\n+      end\n+\n+      def make_editor_with_config(config_path, language)\n+        config_file = Frameit::ConfigParser.new.load(config_path)\n+        screenshot = fake_screenshot(language)\n+\n+        config =config_file.fetch_value(screenshot.path)\n+\n+        editor = Frameit::Editor.new\n+\n+        editor.screenshot = screenshot\n+\n+        #TODO: This should probably be a collaborator instead a mock\n+        expect(editor).to receive(:fetch_config).at_least(:once).and_return config\n+\n+        editor\n+      end\n+\n+      describe 'font typeface' do\n+        it 'finds a font that matches en_US' do\n+          editor = make_editor_with_config('./spec/fixtures/example_frame_file.json', 'en_US')\n+\n+          expect(editor.send(:font, 'title')).to match /fake_western_font.otf/","path":"spec/editor_spec.rb","position":32,"original_position":32,"commit_id":"edb6e0bc92328bf72e9be4e8620fba8174eb1b76","original_commit_id":"edb6e0bc92328bf72e9be4e8620fba8174eb1b76","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"Ambiguous regexp literal. Parenthesize the method arguments if it's surely a regexp literal, or add a whitespace to the right of the `/` if it should be a division.","created_at":"2016-03-02T21:18:43Z","updated_at":"2016-03-02T21:18:43Z","html_url":"https://github.com/fastlane/frameit/pull/111#discussion_r54793015","pull_request_url":"https://api.github.com/repos/fastlane/frameit/pulls/111","_links":{"self":{"href":"https://api.github.com/repos/fastlane/frameit/pulls/comments/54793015"},"html":{"href":"https://github.com/fastlane/frameit/pull/111#discussion_r54793015"},"pull_request":{"href":"https://api.github.com/repos/fastlane/frameit/pulls/111"}}},"pull_request":{"url":"https://api.github.com/repos/fastlane/frameit/pulls/111","id":61468453,"html_url":"https://github.com/fastlane/frameit/pull/111","diff_url":"https://github.com/fastlane/frameit/pull/111.diff","patch_url":"https://github.com/fastlane/frameit/pull/111.patch","issue_url":"https://api.github.com/repos/fastlane/frameit/issues/111","number":111,"state":"open","locked":false,"title":"Add tests for font loading behavior","user":{"login":"i2amsam","id":665326,"avatar_url":"https://avatars.githubusercontent.com/u/665326?v=3","gravatar_id":"","url":"https://api.github.com/users/i2amsam","html_url":"https://github.com/i2amsam","followers_url":"https://api.github.com/users/i2amsam/followers","following_url":"https://api.github.com/users/i2amsam/following{/other_user}","gists_url":"https://api.github.com/users/i2amsam/gists{/gist_id}","starred_url":"https://api.github.com/users/i2amsam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/i2amsam/subscriptions","organizations_url":"https://api.github.com/users/i2amsam/orgs","repos_url":"https://api.github.com/users/i2amsam/repos","events_url":"https://api.github.com/users/i2amsam/events{/privacy}","received_events_url":"https://api.github.com/users/i2amsam/received_events","type":"User","site_admin":false},"body":"Add tests for existing font loading an the new fixed-size from #107 ","created_at":"2016-03-02T21:18:40Z","updated_at":"2016-03-02T21:18:44Z","closed_at":null,"merged_at":null,"merge_commit_sha":"48a3fe799edc718f48be4100b2a3e92fd400ba61","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/fastlane/frameit/pulls/111/commits","review_comments_url":"https://api.github.com/repos/fastlane/frameit/pulls/111/comments","review_comment_url":"https://api.github.com/repos/fastlane/frameit/pulls/comments{/number}","comments_url":"https://api.github.com/repos/fastlane/frameit/issues/111/comments","statuses_url":"https://api.github.com/repos/fastlane/frameit/statuses/edb6e0bc92328bf72e9be4e8620fba8174eb1b76","head":{"label":"fastlane:add-tests-for-font-loading","ref":"add-tests-for-font-loading","sha":"edb6e0bc92328bf72e9be4e8620fba8174eb1b76","user":{"login":"fastlane","id":11098337,"avatar_url":"https://avatars.githubusercontent.com/u/11098337?v=3","gravatar_id":"","url":"https://api.github.com/users/fastlane","html_url":"https://github.com/fastlane","followers_url":"https://api.github.com/users/fastlane/followers","following_url":"https://api.github.com/users/fastlane/following{/other_user}","gists_url":"https://api.github.com/users/fastlane/gists{/gist_id}","starred_url":"https://api.github.com/users/fastlane/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fastlane/subscriptions","organizations_url":"https://api.github.com/users/fastlane/orgs","repos_url":"https://api.github.com/users/fastlane/repos","events_url":"https://api.github.com/users/fastlane/events{/privacy}","received_events_url":"https://api.github.com/users/fastlane/received_events","type":"Organization","site_admin":false},"repo":{"id":26506779,"name":"frameit","full_name":"fastlane/frameit","owner":{"login":"fastlane","id":11098337,"avatar_url":"https://avatars.githubusercontent.com/u/11098337?v=3","gravatar_id":"","url":"https://api.github.com/users/fastlane","html_url":"https://github.com/fastlane","followers_url":"https://api.github.com/users/fastlane/followers","following_url":"https://api.github.com/users/fastlane/following{/other_user}","gists_url":"https://api.github.com/users/fastlane/gists{/gist_id}","starred_url":"https://api.github.com/users/fastlane/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fastlane/subscriptions","organizations_url":"https://api.github.com/users/fastlane/orgs","repos_url":"https://api.github.com/users/fastlane/repos","events_url":"https://api.github.com/users/fastlane/events{/privacy}","received_events_url":"https://api.github.com/users/fastlane/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/fastlane/frameit","description":"Quickly put your screenshots into the right device frames","fork":false,"url":"https://api.github.com/repos/fastlane/frameit","forks_url":"https://api.github.com/repos/fastlane/frameit/forks","keys_url":"https://api.github.com/repos/fastlane/frameit/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fastlane/frameit/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fastlane/frameit/teams","hooks_url":"https://api.github.com/repos/fastlane/frameit/hooks","issue_events_url":"https://api.github.com/repos/fastlane/frameit/issues/events{/number}","events_url":"https://api.github.com/repos/fastlane/frameit/events","assignees_url":"https://api.github.com/repos/fastlane/frameit/assignees{/user}","branches_url":"https://api.github.com/repos/fastlane/frameit/branches{/branch}","tags_url":"https://api.github.com/repos/fastlane/frameit/tags","blobs_url":"https://api.github.com/repos/fastlane/frameit/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fastlane/frameit/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fastlane/frameit/git/refs{/sha}","trees_url":"https://api.github.com/repos/fastlane/frameit/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fastlane/frameit/statuses/{sha}","languages_url":"https://api.github.com/repos/fastlane/frameit/languages","stargazers_url":"https://api.github.com/repos/fastlane/frameit/stargazers","contributors_url":"https://api.github.com/repos/fastlane/frameit/contributors","subscribers_url":"https://api.github.com/repos/fastlane/frameit/subscribers","subscription_url":"https://api.github.com/repos/fastlane/frameit/subscription","commits_url":"https://api.github.com/repos/fastlane/frameit/commits{/sha}","git_commits_url":"https://api.github.com/repos/fastlane/frameit/git/commits{/sha}","comments_url":"https://api.github.com/repos/fastlane/frameit/comments{/number}","issue_comment_url":"https://api.github.com/repos/fastlane/frameit/issues/comments{/number}","contents_url":"https://api.github.com/repos/fastlane/frameit/contents/{+path}","compare_url":"https://api.github.com/repos/fastlane/frameit/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fastlane/frameit/merges","archive_url":"https://api.github.com/repos/fastlane/frameit/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fastlane/frameit/downloads","issues_url":"https://api.github.com/repos/fastlane/frameit/issues{/number}","pulls_url":"https://api.github.com/repos/fastlane/frameit/pulls{/number}","milestones_url":"https://api.github.com/repos/fastlane/frameit/milestones{/number}","notifications_url":"https://api.github.com/repos/fastlane/frameit/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fastlane/frameit/labels{/name}","releases_url":"https://api.github.com/repos/fastlane/frameit/releases{/id}","deployments_url":"https://api.github.com/repos/fastlane/frameit/deployments","created_at":"2014-11-11T21:58:24Z","updated_at":"2016-02-28T21:43:44Z","pushed_at":"2016-03-02T21:18:41Z","git_url":"git://github.com/fastlane/frameit.git","ssh_url":"git@github.com:fastlane/frameit.git","clone_url":"https://github.com/fastlane/frameit.git","svn_url":"https://github.com/fastlane/frameit","homepage":"https://fastlane.tools","size":4277,"stargazers_count":947,"watchers_count":947,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":66,"mirror_url":null,"open_issues_count":40,"forks":66,"open_issues":40,"watchers":947,"default_branch":"master"}},"base":{"label":"fastlane:master","ref":"master","sha":"f8eca13fa99162e898220fe6927da0cf83ad6fb7","user":{"login":"fastlane","id":11098337,"avatar_url":"https://avatars.githubusercontent.com/u/11098337?v=3","gravatar_id":"","url":"https://api.github.com/users/fastlane","html_url":"https://github.com/fastlane","followers_url":"https://api.github.com/users/fastlane/followers","following_url":"https://api.github.com/users/fastlane/following{/other_user}","gists_url":"https://api.github.com/users/fastlane/gists{/gist_id}","starred_url":"https://api.github.com/users/fastlane/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fastlane/subscriptions","organizations_url":"https://api.github.com/users/fastlane/orgs","repos_url":"https://api.github.com/users/fastlane/repos","events_url":"https://api.github.com/users/fastlane/events{/privacy}","received_events_url":"https://api.github.com/users/fastlane/received_events","type":"Organization","site_admin":false},"repo":{"id":26506779,"name":"frameit","full_name":"fastlane/frameit","owner":{"login":"fastlane","id":11098337,"avatar_url":"https://avatars.githubusercontent.com/u/11098337?v=3","gravatar_id":"","url":"https://api.github.com/users/fastlane","html_url":"https://github.com/fastlane","followers_url":"https://api.github.com/users/fastlane/followers","following_url":"https://api.github.com/users/fastlane/following{/other_user}","gists_url":"https://api.github.com/users/fastlane/gists{/gist_id}","starred_url":"https://api.github.com/users/fastlane/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fastlane/subscriptions","organizations_url":"https://api.github.com/users/fastlane/orgs","repos_url":"https://api.github.com/users/fastlane/repos","events_url":"https://api.github.com/users/fastlane/events{/privacy}","received_events_url":"https://api.github.com/users/fastlane/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/fastlane/frameit","description":"Quickly put your screenshots into the right device frames","fork":false,"url":"https://api.github.com/repos/fastlane/frameit","forks_url":"https://api.github.com/repos/fastlane/frameit/forks","keys_url":"https://api.github.com/repos/fastlane/frameit/keys{/key_id}","collaborators_url":"https://api.github.com/repos/fastlane/frameit/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/fastlane/frameit/teams","hooks_url":"https://api.github.com/repos/fastlane/frameit/hooks","issue_events_url":"https://api.github.com/repos/fastlane/frameit/issues/events{/number}","events_url":"https://api.github.com/repos/fastlane/frameit/events","assignees_url":"https://api.github.com/repos/fastlane/frameit/assignees{/user}","branches_url":"https://api.github.com/repos/fastlane/frameit/branches{/branch}","tags_url":"https://api.github.com/repos/fastlane/frameit/tags","blobs_url":"https://api.github.com/repos/fastlane/frameit/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/fastlane/frameit/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/fastlane/frameit/git/refs{/sha}","trees_url":"https://api.github.com/repos/fastlane/frameit/git/trees{/sha}","statuses_url":"https://api.github.com/repos/fastlane/frameit/statuses/{sha}","languages_url":"https://api.github.com/repos/fastlane/frameit/languages","stargazers_url":"https://api.github.com/repos/fastlane/frameit/stargazers","contributors_url":"https://api.github.com/repos/fastlane/frameit/contributors","subscribers_url":"https://api.github.com/repos/fastlane/frameit/subscribers","subscription_url":"https://api.github.com/repos/fastlane/frameit/subscription","commits_url":"https://api.github.com/repos/fastlane/frameit/commits{/sha}","git_commits_url":"https://api.github.com/repos/fastlane/frameit/git/commits{/sha}","comments_url":"https://api.github.com/repos/fastlane/frameit/comments{/number}","issue_comment_url":"https://api.github.com/repos/fastlane/frameit/issues/comments{/number}","contents_url":"https://api.github.com/repos/fastlane/frameit/contents/{+path}","compare_url":"https://api.github.com/repos/fastlane/frameit/compare/{base}...{head}","merges_url":"https://api.github.com/repos/fastlane/frameit/merges","archive_url":"https://api.github.com/repos/fastlane/frameit/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/fastlane/frameit/downloads","issues_url":"https://api.github.com/repos/fastlane/frameit/issues{/number}","pulls_url":"https://api.github.com/repos/fastlane/frameit/pulls{/number}","milestones_url":"https://api.github.com/repos/fastlane/frameit/milestones{/number}","notifications_url":"https://api.github.com/repos/fastlane/frameit/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/fastlane/frameit/labels{/name}","releases_url":"https://api.github.com/repos/fastlane/frameit/releases{/id}","deployments_url":"https://api.github.com/repos/fastlane/frameit/deployments","created_at":"2014-11-11T21:58:24Z","updated_at":"2016-02-28T21:43:44Z","pushed_at":"2016-03-02T21:18:41Z","git_url":"git://github.com/fastlane/frameit.git","ssh_url":"git@github.com:fastlane/frameit.git","clone_url":"https://github.com/fastlane/frameit.git","svn_url":"https://github.com/fastlane/frameit","homepage":"https://fastlane.tools","size":4277,"stargazers_count":947,"watchers_count":947,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":66,"mirror_url":null,"open_issues_count":40,"forks":66,"open_issues":40,"watchers":947,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/fastlane/frameit/pulls/111"},"html":{"href":"https://github.com/fastlane/frameit/pull/111"},"issue":{"href":"https://api.github.com/repos/fastlane/frameit/issues/111"},"comments":{"href":"https://api.github.com/repos/fastlane/frameit/issues/111/comments"},"review_comments":{"href":"https://api.github.com/repos/fastlane/frameit/pulls/111/comments"},"review_comment":{"href":"https://api.github.com/repos/fastlane/frameit/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/fastlane/frameit/pulls/111/commits"},"statuses":{"href":"https://api.github.com/repos/fastlane/frameit/statuses/edb6e0bc92328bf72e9be4e8620fba8174eb1b76"}}}}