task_id int64 0 2.26k | repository stringclasses 18
values | commit_hash stringclasses 241
values | filepath stringclasses 237
values | original_method stringlengths 21 4.65k | context listlengths 0 77 | masking dict |
|---|---|---|---|---|---|---|
100 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBBlogTest.class.st | testRemovePost
| count |
count := blog allPosts size.
blog removePost: (blog allPosts at: 1).
self assert: blog allPosts size equals: count - 1. | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "testRemovePost\n\t\n\t| count |\n\t\n\tcount :=",
"suffix": ".\n\tblog removePost: (blog allPosts at: 1).\n\tself assert: blog allPosts size equals: count - 1.",
"completion": " blog allPosts size"
} |
101 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBBlogTest.class.st | testRemovePost
| count |
count := blog allPosts size.
blog removePost: (blog allPosts at: 1).
self assert: blog allPosts size equals: count - 1. | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testRemovePost\n\t\n\t| count |\n\t\n\tcount := blog allPosts size.\n\tblog removePost: (blog",
"suffix": ".\n\tself assert: blog allPosts size equals: count - 1.",
"completion": " allPosts at: 1)"
} |
102 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBBlogTest.class.st | testRemovePost
| count |
count := blog allPosts size.
blog removePost: (blog allPosts at: 1).
self assert: blog allPosts size equals: count - 1. | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testRemovePost\n\t\n\t| count |\n\t\n\tcount := blog allPosts size.\n\tblog removePost: (blog allPosts at: 1).\n\tself assert: blog allPosts",
"suffix": ".",
"completion": " size equals: count - 1"
} |
103 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPost.class.st | descriptionCategory
<magritteDescription>
^ MAStringDescription new
label: 'Category';
priority: 300;
accessor: #category;
comment: 'Unclassified if empty';
componentClass: TBSMagritteTextInputComponent;
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 5,
"prefix": "descriptionCategory\n\t\n\t<magritteDescription>\n\t^ MAStringDescription new\n\t\tlabel: 'Category';\n\t\tpriority: 300;\n\t\taccessor: #category;\n\t\tcomment: 'Unclassified if empty'",
"suffix": "",
"completion": ";\n\t\tcomponentCla... |
104 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPost.class.st | descriptionContainer
<magritteContainer>
^ super descriptionContainer
componentRenderer: TBSMagritteFormRenderer;
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 3,
"prefix": "descriptionContainer\n\n\t<magritteContainer>\n\t^ super descriptionContainer\n\t\tcomponentRenderer:",
"suffix": "",
"completion": " TBSMagritteFormRenderer;\n\t\tyourself"
} |
105 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPost.class.st | descriptionDate
<magritteDescription>
^ MADateDescription new
label: 'Date';
priority: 400;
accessor: #date;
beRequired;
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 7,
"prefix": "descriptionDate\n\n\t<magritteDescription>\n\t^ MADateDescription new\n\t\tlabel: 'Date';\n\t\tpriority: 400",
"suffix": "",
"completion": ";\n\t\taccessor: #date;\n\t\tbeRequired;\n\t\tyourself"
} |
106 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPost.class.st | descriptionText
<magritteDescription>
^ MAMemoDescription new
label: 'Text';
priority: 200;
accessor: #text;
beRequired;
requiredErrorMessage: 'A blog post must contain a text.';
comment: 'Please enter a text';
componentClass: TBSMagritteTextAreaComponent;
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 6,
"prefix": "descriptionText\n\t\n\t<magritteDescription>\n\t^ MAMemoDescription new\n\t\tlabel: 'Text';\n\t\tpriority: 200;\n\t\taccessor: #text;\n\t\tbeRequired;\n\t\trequiredErrorMessage: 'A blog post must contain a text.';\n\t\tcomment:",
"suffix"... |
107 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPost.class.st | descriptionTitle
<magritteDescription>
^ MAStringDescription new
label: 'Title';
priority: 100;
accessor: #title;
requiredErrorMessage: 'A blog post must have a title.';
comment: 'Please enter a title';
componentClass: TBSMagritteTextInputComponent;
beRequired;
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 4,
"prefix": "descriptionTitle\n\n\t<magritteDescription>\n\t^ MAStringDescription new\n\t\tlabel: 'Title';\n\t\tpriority: 100;\n\t\taccessor: #title;\n\t\trequiredErrorMessage: 'A blog post must have a title.';\n\t\tcomment: 'Please enter a title';\n\t\... |
108 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPost.class.st | descriptionVisible
<magritteDescription>
^ MABooleanDescription new
checkboxLabel: 'Visible';
priority: 500;
accessor: #visible;
componentClass: TBSMagritteCheckboxComponent;
beRequired;
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 8,
"prefix": "descriptionVisible\n\t\n\t<magritteDescription>\n\t^ MABooleanDescription new\n\t\tcheckboxLabel: 'Visible';\n\t\tpriority: 500;\n\t\taccessor:",
"suffix": "",
"completion": " #visible;\n\t\tcomponentClass: TBSMagritteCheckboxComponent;... |
109 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | filteredDescriptionsFrom: aBlogPost
^ aBlogPost magritteDescription
select: [ :each | #(title category date) includes: each accessor selector ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 7,
"prefix": "filteredDescriptionsFrom: aBlogPost\n\n\t^ aBlogPost magritteDescription\n\t\tselect: [ :each | #(title category",
"suffix": "",
"completion": " date) includes: each accessor selector ]"
} |
110 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | filteredDescriptionsFrom: aBlogPost
^ aBlogPost magritteDescription
select: [ :each | #(title category date) includes: each accessor selector ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "filteredDescriptionsFrom: aBlogPost\n\n\t^ aBlogPost magritteDescription\n\t\tselect: [ :each | #(title category date",
"suffix": " ]",
"completion": ") includes: each accessor selector"
} |
111 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | from: aBlog
| allPlogs report |
allPlogs := aBlog allPosts.
report := self rows: allPlogs description: (self filteredDescriptionsFrom: allPlogs anyOne).
report blog: aBlog.
report addColumn: (MACommandColumn new addCommandOn: report selector: #viewPost: text: 'View';
yourself;
addCommandOn: report selector:... | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "from: aBlog\n\n\t| allPlogs report |\n\t\n\tallPlogs",
"suffix": ".\n\treport := self rows: allPlogs description: (self filteredDescriptionsFrom: allPlogs anyOne).\n\treport blog: aBlog.\n\treport addColumn: (MACommandColumn new addCo... |
112 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | from: aBlog
| allPlogs report |
allPlogs := aBlog allPosts.
report := self rows: allPlogs description: (self filteredDescriptionsFrom: allPlogs anyOne).
report blog: aBlog.
report addColumn: (MACommandColumn new addCommandOn: report selector: #viewPost: text: 'View';
yourself;
addCommandOn: report selector:... | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 1,
"mask_type": "assignment",
"n_masked_tokens": 9,
"prefix": "from: aBlog\n\n\t| allPlogs report |\n\t\n\tallPlogs := aBlog allPosts.\n\treport := self",
"suffix": ".\n\treport blog: aBlog.\n\treport addColumn: (MACommandColumn new addCommandOn: report selector: #viewPost: text: 'View';\n\t\tyou... |
113 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | from: aBlog
| allPlogs report |
allPlogs := aBlog allPosts.
report := self rows: allPlogs description: (self filteredDescriptionsFrom: allPlogs anyOne).
report blog: aBlog.
report addColumn: (MACommandColumn new addCommandOn: report selector: #viewPost: text: 'View';
yourself;
addCommandOn: report selector:... | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 6,
"prefix": "from: aBlog\n\n\t| allPlogs report |\n\t\n\tallPlogs := aBlog allPosts.\n\treport := self rows: allPlogs description: (self filteredDescriptionsFrom: allPlogs anyOne).\n\treport blog: aBlog.\n\treport addColumn: (MACommandColumn ne... |
114 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | addPost
| post |
post := self call: (self renderAddPostForm: MyTBPost new).
post ifNotNil: [ :arg | blog addPost: post. self refreshReport ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 6,
"prefix": "addPost\n\n\t| post |\n\n\tpost := self call:",
"suffix": ".\n\tpost ifNotNil: [ :arg | blog addPost: post. self refreshReport ]",
"completion": " (self renderAddPostForm: MyTBPost new)"
} |
115 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | addPost
| post |
post := self call: (self renderAddPostForm: MyTBPost new).
post ifNotNil: [ :arg | blog addPost: post. self refreshReport ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 6,
"prefix": "addPost\n\n\t| post |\n\n\tpost := self call: (self renderAddPostForm: MyTBPost new).\n\tpost ifNotNil: [ :arg | blog",
"suffix": "",
"completion": " addPost: post. self refreshReport ]"
} |
116 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | deletePost: aPost
(self confirm: 'Do you want remove this post ?')
ifFalse: [ ^ self ].
blog removeBlogPost: aPost.
self refreshReport | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "deletePost: aPost\n\n\t(self confirm: 'Do you want remove this post ?')\n\t\tifFalse: [",
"suffix": ".\n\tblog removeBlogPost: aPost.\n\tself refreshReport",
"completion": " ^ self ]"
} |
117 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | editPost: aPost
| post |
post := self call: (self renderEditPostForm: aPost).
post ifNotNil: [ :arg | blog save ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "editPost: aPost\n\n\t| post |\n\n\tpost := self call: (self",
"suffix": ".\n\tpost ifNotNil: [ :arg | blog save ]",
"completion": " renderEditPostForm: aPost)"
} |
118 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | editPost: aPost
| post |
post := self call: (self renderEditPostForm: aPost).
post ifNotNil: [ :arg | blog save ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 8,
"prefix": "editPost: aPost\n\n\t| post |\n\n\tpost := self call: (self renderEditPostForm: aPost).\n\tpost",
"suffix": "",
"completion": " ifNotNil: [ :arg | blog save ]"
} |
119 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | refreshReport
self rows: blog allPosts.
self refresh. | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "refreshReport\n\n\tself",
"suffix": ".\n\tself refresh.",
"completion": " rows: blog allPosts"
} |
120 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | renderAddPostForm: aPost
^ aPost asComponent
addDecoration: (TBSMagritteFormDecoration buttons: { #save -> 'Add post' . #cancel -> 'Cancel'});
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 7,
"prefix": "renderAddPostForm: aPost\n\n\t^ aPost asComponent\n\t\taddDecoration: (TBSMagritteFormDecoration buttons: { #save -> 'Add post' .",
"suffix": "",
"completion": " #cancel -> 'Cancel'});\n\t\tyourself"
} |
121 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | renderContentOn: html
html tbsGlyphIcon iconPencil.
html anchor callback: [ self addPost ]; with: 'Add post'.
super renderContentOn: html | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "cascade",
"n_masked_tokens": 8,
"prefix": "renderContentOn: html\n\n\thtml tbsGlyphIcon iconPencil.\n\thtml anchor",
"suffix": ".\n\tsuper renderContentOn: html",
"completion": " callback: [ self addPost ]; with: 'Add post'"
} |
122 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | renderEditPostForm: aPost
^ aPost asComponent
addDecoration:
(TBSMagritteFormDecoration
buttons: {(#save -> 'Save post'). (#cancel -> 'Cancel')});
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 10,
"prefix": "renderEditPostForm: aPost\n\t\n\t^ aPost asComponent\n\t\taddDecoration:\n\t\t\t(TBSMagritteFormDecoration\n\t\t\t\tbuttons: {(#save -> 'Save post')",
"suffix": "",
"completion": ". (#cancel -> 'Cancel')});\n\t\tyourself"
} |
123 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | renderViewPostForm: aPost
^ aPost asComponent
addDecoration: (TBSMagritteFormDecoration buttons: { #cancel -> 'Back' });
readonly: true;
yourself | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 4,
"prefix": "renderViewPostForm: aPost\n\n\t^ aPost asComponent\n\t\taddDecoration: (TBSMagritteFormDecoration buttons: { #cancel -> 'Back' });",
"suffix": "",
"completion": "\n\t\treadonly: true;\n\t\tyourself"
} |
124 | https://github.com/matijakljajic/oxo-pharo | aae4f642cf0dc1a3a71fdaf190f88863381770e2 | src/MyTinyBlog/MyTBPostReport.class.st | viewPost: aPost
self call: (self renderViewPostForm: aPost) | [
{
"filepath": "repo_clone/oxo-pharo/src/MyTinyBlog/MyTBPostListComponent.class.st",
"code": "MyTBAppScreenComponent subclass: #MyTBPostListComponent\n\tinstanceVariableNames: 'currentCategory showLoginError'\n\tclassVariableNames: ''\n\tpackage: 'MyTinyBlog-Components'"
},
{
"filepath": "repo_clone/... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "viewPost: aPost\n\n\tself call: (",
"suffix": "",
"completion": "self renderViewPostForm: aPost)"
} |
125 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | initialize
| app |
app := WAAdmin register: self asApplicationAt: 'MyCounter'.
app
addLibrary: JQDeploymentLibrary;
addLibrary: TBSDevelopmentLibrary | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 6,
"prefix": "initialize\n\n\t| app |\n\n\tapp",
"suffix": ".\n\tapp\n\t\taddLibrary: JQDeploymentLibrary;\n\t\taddLibrary: TBSDevelopmentLibrary",
"completion": " := WAAdmin register: self asApplicationAt: 'MyCounter'"
} |
126 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | initialize
| app |
app := WAAdmin register: self asApplicationAt: 'MyCounter'.
app
addLibrary: JQDeploymentLibrary;
addLibrary: TBSDevelopmentLibrary | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 1,
"mask_type": "cascade",
"n_masked_tokens": 4,
"prefix": "initialize\n\n\t| app |\n\n\tapp := WAAdmin register: self asApplicationAt: 'MyCounter'.\n\tapp\n\t\taddLibrary:",
"suffix": "",
"completion": " JQDeploymentLibrary;\n\t\taddLibrary: TBSDevelopmentLibrary"
} |
127 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | startingAt: anInteger
^ self new count: anInteger | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 3,
"prefix": "startingAt: anInteger\n\t^ self",
"suffix": "",
"completion": " new count: anInteger"
} |
128 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | decrement
self count: count - 1 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "decrement\n\tself",
"suffix": "",
"completion": " count: count - 1"
} |
129 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | increment
self count: count + 1 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "increment\n\tself",
"suffix": "",
"completion": " count: count + 1"
} |
130 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | printOn: aStream
"Append a sequence of characters to aStream that identify the receiver."
super printOn: aStream.
aStream
nextPutAll: ' with count: ';
print: count | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "cascade",
"n_masked_tokens": 3,
"prefix": "printOn: aStream\n\t\"Append a sequence of characters to aStream that identify the receiver.\"\n\n\tsuper printOn: aStream.\n\taStream\n\t\tnextPutAll: ' with count: '",
"suffix": "",
"completion": ";\n\t\tprint: count"
} |
131 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | renderContentOn: html
html form: [
html tbsBadge: self count; space.
html tbsButtonGroup beSmall;
with: [
html tbsButton beDefault;
callback: [ self increment ]; with: '+'.
html tbsButton beDefault;
callback: [ self decrement ]; with: '-' ] ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 3,
"mask_type": "cascade",
"n_masked_tokens": 10,
"prefix": "renderContentOn: html\n\n\thtml form: [ \n\t\t\thtml tbsBadge: self count; space.\n\t\t\thtml tbsButtonGroup beSmall; \n\t\t\t\twith: [ \n\t\t\t\t\thtml tbsButton",
"suffix": ".\n\t\t\t\t\thtml tbsButton beDefault;\n\t\t\t\t\t\tcallback... |
132 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | renderContentOn: html
html form: [
html tbsBadge: self count; space.
html tbsButtonGroup beSmall;
with: [
html tbsButton beDefault;
callback: [ self increment ]; with: '+'.
html tbsButton beDefault;
callback: [ self decrement ]; with: '-' ] ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 2,
"mask_type": "cascade",
"n_masked_tokens": 4,
"prefix": "renderContentOn: html\n\n\thtml form: [ \n\t\t\thtml tbsBadge: self count; space.\n\t\t\thtml tbsButtonGroup beSmall; \n\t\t\t\twith: [ \n\t\t\t\t\thtml tbsButton beDefault;\n\t\t\t\t\t\tcallback: [ self increment ]; with: '+'.\n\t\t\t\t\t... |
133 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | renderContentOn: html
html form: [
html tbsBadge: self count; space.
html tbsButtonGroup beSmall;
with: [
html tbsButton beDefault;
callback: [ self increment ]; with: '+'.
html tbsButton beDefault;
callback: [ self decrement ]; with: '-' ] ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 6,
"prefix": "renderContentOn: html\n\n\thtml form: [ \n\t\t\thtml tbsBadge: self count; space.\n\t\t\thtml tbsButtonGroup beSmall; \n\t\t\t\twith: [ \n\t\t\t\t\thtml tbsButton beDefault;\n\t\t\t\t\t\tcallback: [ self increment ]; with: '+'.\n\t... |
134 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounter.class.st | states
^ Array with: self | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 3,
"prefix": "states\n\n\t^",
"suffix": "",
"completion": " Array with: self"
} |
135 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testCounterDecrement
| c |
c := MyCounter new.
c count: 2.
c decrement decrement.
self assert: c count equals: 0 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testS... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "testCounterDecrement\n\n\t| c |\n\n\tc",
"suffix": ".\n\tc count: 2.\n\tc decrement decrement.\n\tself assert: c count equals: 0",
"completion": " := MyCounter new"
} |
136 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testCounterDecrement
| c |
c := MyCounter new.
c count: 2.
c decrement decrement.
self assert: c count equals: 0 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testS... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testCounterDecrement\n\n\t| c |\n\n\tc := MyCounter new.\n\tc count: 2.\n\tc decrement decrement.\n\tself",
"suffix": "",
"completion": " assert: c count equals: 0"
} |
137 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testCounterIncrement
| c |
c := MyCounter new.
c count: 8.
c increment increment.
self assert: c count equals: 10 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testS... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "testCounterIncrement\n\n\t| c |\n\n\tc",
"suffix": ".\n\tc count: 8.\n\tc increment increment.\n\tself assert: c count equals: 10",
"completion": " := MyCounter new"
} |
138 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testCounterIncrement
| c |
c := MyCounter new.
c count: 8.
c increment increment.
self assert: c count equals: 10 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testS... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCounterIncrement\n\n\t| c |\n\n\tc := MyCounter new.\n\tc count: 8.\n\tc increment increment.\n\tself assert:",
"suffix": "",
"completion": " c count equals: 10"
} |
139 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testCounterSetAndRead
| c |
c := MyCounter new.
c count: 10.
self assert: c count equals: 10 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testS... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "testCounterSetAndRead\n\n\t| c |\n\n\tc",
"suffix": ".\n\tc count: 10.\n\tself assert: c count equals: 10",
"completion": " := MyCounter new"
} |
140 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testCounterSetAndRead
| c |
c := MyCounter new.
c count: 10.
self assert: c count equals: 10 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testS... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCounterSetAndRead\n\n\t| c |\n\n\tc := MyCounter new.\n\tc count: 10.\n\tself assert: c",
"suffix": "",
"completion": " count equals: 10"
} |
141 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testStartingAt5
| c |
c := MyCounter startingAt: 5.
self assert: c count equals: 5 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 4,
"prefix": "testStartingAt5\n\n\t| c |\n\n\tc",
"suffix": ".\n\tself assert: c count equals: 5",
"completion": " := MyCounter startingAt: 5"
} |
142 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounterTest.class.st | testStartingAt5
| c |
c := MyCounter startingAt: 5.
self assert: c count equals: 5 | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testStartingAt5\n\n\t| c |\n\n\tc := MyCounter startingAt: 5.\n\tself",
"suffix": "",
"completion": " assert: c count equals: 5"
} |
143 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounters.class.st | initialize
| app |
app := WAAdmin register: self asApplicationAt: 'MyCounters'.
app
addLibrary: JQDeploymentLibrary;
addLibrary: TBSDevelopmentLibrary | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 4,
"prefix": "initialize\n\t\n\t| app |\n\n\tapp := WAAdmin",
"suffix": ".\n\tapp\n\t\taddLibrary: JQDeploymentLibrary;\n\t\taddLibrary: TBSDevelopmentLibrary",
"completion": " register: self asApplicationAt: 'MyCounters'"
} |
144 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounters.class.st | initialize
| app |
app := WAAdmin register: self asApplicationAt: 'MyCounters'.
app
addLibrary: JQDeploymentLibrary;
addLibrary: TBSDevelopmentLibrary | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 1,
"mask_type": "cascade",
"n_masked_tokens": 4,
"prefix": "initialize\n\t\n\t| app |\n\n\tapp := WAAdmin register: self asApplicationAt: 'MyCounters'.\n\tapp\n\t\taddLibrary:",
"suffix": "",
"completion": " JQDeploymentLibrary;\n\t\taddLibrary: TBSDevelopmentLibrary"
} |
145 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounters.class.st | initialize
super initialize.
counts := (1 to: 5) collect: [ :each | MyCounter new ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "initialize\n\t\n\tsuper initialize.\n\tcounts := (1 to: 5) collect: [ :each |",
"suffix": "",
"completion": " MyCounter new ]"
} |
146 | https://github.com/matijakljajic/oxo-pharo | 74c10979245709179e7059b0dace47b3d6b426bf | src/MyCounter/MyCounters.class.st | renderContentOn: html
counts do: [ :c | html render: c ] | [
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "TestCase subclass: #MyCounterTest\n\tinstanceVariableNames: ''\n\tclassVariableNames: ''\n\tpackage: 'MyCounter-Tests'"
},
{
"filepath": "repo_clone/oxo-pharo/src/MyCounter/MyCounterTest.class.st",
"code": "testC... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 9,
"prefix": "renderContentOn: html\n\t\n\tcounts",
"suffix": "",
"completion": " do: [ :c | html render: c ]"
} |
147 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testAtAt
| cell |
cell := OXOCell at: 2 at: 3.
self assert: cell row equals: 2.
self assert: cell col equals: 3 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 5,
"prefix": "testAtAt\n\n\t| cell |\n\tcell :=",
"suffix": ".\n\n\tself assert: cell row equals: 2.\n\tself assert: cell col equals: 3",
"completion": " OXOCell at: 2 at: 3"
} |
148 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testAtAt
| cell |
cell := OXOCell at: 2 at: 3.
self assert: cell row equals: 2.
self assert: cell col equals: 3 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testAtAt\n\n\t| cell |\n\tcell := OXOCell at: 2 at: 3.\n\n\tself",
"suffix": ".\n\tself assert: cell col equals: 3",
"completion": " assert: cell row equals: 2"
} |
149 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testAtAt
| cell |
cell := OXOCell at: 2 at: 3.
self assert: cell row equals: 2.
self assert: cell col equals: 3 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testAtAt\n\n\t| cell |\n\tcell := OXOCell at: 2 at: 3.\n\n\tself assert: cell row equals: 2.\n\tself",
"suffix": "",
"completion": " assert: cell col equals: 3"
} |
150 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testCol
| cell |
cell := OXOCell new col: 3.
self assert: cell col equals: 3.
self should: [ cell col: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "testCol\n\n\t| cell |\n\tcell := OXOCell",
"suffix": ".\n\n\tself assert: cell col equals: 3.\n\n\tself should: [ cell col: 1 ] raise: Error",
"completion": " new col: 3"
} |
151 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testCol
| cell |
cell := OXOCell new col: 3.
self assert: cell col equals: 3.
self should: [ cell col: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCol\n\n\t| cell |\n\tcell := OXOCell new col: 3.\n\n\tself assert: cell",
"suffix": ".\n\n\tself should: [ cell col: 1 ] raise: Error",
"completion": " col equals: 3"
} |
152 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testCol
| cell |
cell := OXOCell new col: 3.
self assert: cell col equals: 3.
self should: [ cell col: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 6,
"prefix": "testCol\n\n\t| cell |\n\tcell := OXOCell new col: 3.\n\n\tself assert: cell col equals: 3.\n\n\tself should: [",
"suffix": "",
"completion": " cell col: 1 ] raise: Error"
} |
153 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testRow
| cell |
cell := OXOCell new row: 2.
self assert: cell row equals: 2.
self should: [ cell row: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "testRow\n\n\t| cell |\n\tcell := OXOCell",
"suffix": ".\n\n\tself assert: cell row equals: 2.\n\n\tself should: [ cell row: 1 ] raise: Error",
"completion": " new row: 2"
} |
154 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testRow
| cell |
cell := OXOCell new row: 2.
self assert: cell row equals: 2.
self should: [ cell row: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testRow\n\n\t| cell |\n\tcell := OXOCell new row: 2.\n\n\tself",
"suffix": ".\n\n\tself should: [ cell row: 1 ] raise: Error",
"completion": " assert: cell row equals: 2"
} |
155 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testRow
| cell |
cell := OXOCell new row: 2.
self assert: cell row equals: 2.
self should: [ cell row: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 7,
"prefix": "testRow\n\n\t| cell |\n\tcell := OXOCell new row: 2.\n\n\tself assert: cell row equals: 2.\n\n\tself should:",
"suffix": "",
"completion": " [ cell row: 1 ] raise: Error"
} |
156 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testState
| cell |
cell := OXOCell new.
cell state: 'X'.
self assert: cell state equals: 'X'.
self should: [ cell state: 'O' ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "testState\n\n\t| cell |\n\tcell",
"suffix": ".\n\tcell state: 'X'.\n\n\tself assert: cell state equals: 'X'.\n\n\tself should: [ cell state: 'O' ] raise: Error",
"completion": " := OXOCell new"
} |
157 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testState
| cell |
cell := OXOCell new.
cell state: 'X'.
self assert: cell state equals: 'X'.
self should: [ cell state: 'O' ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testState\n\n\t| cell |\n\tcell := OXOCell new.\n\tcell state: 'X'.\n\n\tself assert: cell",
"suffix": ".\n\n\tself should: [ cell state: 'O' ] raise: Error",
"completion": " state equals: 'X'"
} |
158 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOCellTest.class.st | testState
| cell |
cell := OXOCell new.
cell state: 'X'.
self assert: cell state equals: 'X'.
self should: [ cell state: 'O' ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 8,
"prefix": "testState\n\n\t| cell |\n\tcell := OXOCell new.\n\tcell state: 'X'.\n\n\tself assert: cell state equals: 'X'.\n\n\tself",
"suffix": "",
"completion": " should: [ cell state: 'O' ] raise: Error"
} |
159 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | setUp
super setUp.
oxo := OXOGrid new. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "setUp\n\n\tsuper setUp.\n\t\n\toxo",
"suffix": ".",
"completion": " := OXOGrid new"
} |
160 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testAddMove
self assert: oxo moves equals: 0.
oxo at: 1 at: 1.
self assert: oxo moves equals: 1 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testAddMove\n\n\tself assert: oxo",
"suffix": ".\n\n\toxo at: 1 at: 1.\n\n\tself assert: oxo moves equals: 1",
"completion": " moves equals: 0"
} |
161 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testAddMove
self assert: oxo moves equals: 0.
oxo at: 1 at: 1.
self assert: oxo moves equals: 1 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testAddMove\n\n\tself assert: oxo moves equals: 0.\n\n\toxo",
"suffix": ".\n\n\tself assert: oxo moves equals: 1",
"completion": " at: 1 at: 1"
} |
162 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testAddMove
self assert: oxo moves equals: 0.
oxo at: 1 at: 1.
self assert: oxo moves equals: 1 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testAddMove\n\n\tself assert: oxo moves equals: 0.\n\n\toxo at: 1 at: 1.\n\n\tself assert: oxo",
"suffix": "",
"completion": " moves equals: 1"
} |
163 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testAtAt
self assert: oxo moves equals: 0.
oxo at: 1 at: 1.
self
assert: (oxo grid at: 1 at: 1) state equals: 'O';
assert: oxo moves equals: 1.
self should: [ oxo at: 1 at: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testAtAt\n\n\tself assert: oxo moves equals: 0.\n\toxo at:",
"suffix": ".\n\tself\n\t\tassert: (oxo grid at: 1 at: 1) state equals: 'O';\n\t\tassert: oxo moves equals: 1.\n\n\tself should: [ oxo at: 1 at: 1 ] raise: Error",
"co... |
164 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testAtAt
self assert: oxo moves equals: 0.
oxo at: 1 at: 1.
self
assert: (oxo grid at: 1 at: 1) state equals: 'O';
assert: oxo moves equals: 1.
self should: [ oxo at: 1 at: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "cascade",
"n_masked_tokens": 8,
"prefix": "testAtAt\n\n\tself assert: oxo moves equals: 0.\n\toxo at: 1 at: 1.\n\tself\n\t\tassert: (oxo grid at: 1 at: 1) state",
"suffix": ".\n\n\tself should: [ oxo at: 1 at: 1 ] raise: Error",
"completion": " equals: 'O';\n\t\tassert: oxo mov... |
165 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testAtAt
self assert: oxo moves equals: 0.
oxo at: 1 at: 1.
self
assert: (oxo grid at: 1 at: 1) state equals: 'O';
assert: oxo moves equals: 1.
self should: [ oxo at: 1 at: 1 ] raise: Error | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testAtAt\n\n\tself assert:",
"suffix": ".\n\toxo at: 1 at: 1.\n\tself\n\t\tassert: (oxo grid at: 1 at: 1) state equals: 'O';\n\t\tassert: oxo moves equals: 1.\n\n\tself should: [ oxo at: 1 at: 1 ] raise: Error",
"completion": "... |
166 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInCol
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 2 at: 3.
self assert: (oxo checkInCol: 2) equals: nil.
self assert: (oxo checkInCol: 3) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 4,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCheckInCol\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at:",
"suffix": ".\n\toxo at: 2 at: 2.\n\toxo at: 2 at: 3.\n\t\n\tself assert: (oxo checkInCol: 2) equals: nil.\n\tself asser... |
167 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInCol
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 2 at: 3.
self assert: (oxo checkInCol: 2) equals: nil.
self assert: (oxo checkInCol: 3) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 3,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckInCol\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo",
"suffix": ".\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 2 at: 3.\n\t\n\tself assert: (oxo checkInCol: 2) equals: nil.\n\tself assert: (... |
168 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInCol
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 2 at: 3.
self assert: (oxo checkInCol: 2) equals: nil.
self assert: (oxo checkInCol: 3) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckInCol\n\n\toxo at: 1 at: 1.\n\toxo",
"suffix": ".\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 2 at: 3.\n\t\n\tself assert: (oxo checkInCol: 2) equals: nil.\n\tself assert: (... |
169 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInDiagonals
self testCheckInDiagonals1.
self tearDown; setUp.
self testCheckInDiagonals2. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "cascade",
"n_masked_tokens": 3,
"prefix": "testCheckInDiagonals\n\n\tself testCheckInDiagonals1.\n\tself",
"suffix": ".\n\tself testCheckInDiagonals2.",
"completion": " tearDown; setUp"
} |
170 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInDiagonals1
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 3.
oxo at: 2 at: 2.
self assert: (oxo checkInDiagonals) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckInDiagonals1\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo",
"suffix": ".\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 3.\n\toxo at: 2 at: 2.\n\t\n\tself assert: (oxo checkInDiagonals) equals: 'O'.",
"co... |
171 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInDiagonals1
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 3.
oxo at: 2 at: 2.
self assert: (oxo checkInDiagonals) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCheckInDiagonals1\n\n\toxo at: 1 at: 1.\n\toxo at:",
"suffix": ".\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 3.\n\toxo at: 2 at: 2.\n\t\n\tself assert: (oxo checkInDiagonals) equals: 'O'.",
... |
172 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInDiagonals1
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 3.
oxo at: 2 at: 2.
self assert: (oxo checkInDiagonals) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 7,
"mask_type": "keyword_message",
"n_masked_tokens": 7,
"prefix": "testCheckInDiagonals1\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 3.\n\toxo at: 2 at: 2.\n\t\n\tself",
"suffix": ".",
"completion": " assert: (oxo check... |
173 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInDiagonals2
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 1.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 3.
oxo at: 2 at: 2.
self assert: (oxo checkInDiagonals) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 5,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckInDiagonals2\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 1.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo",
"suffix": ".\n\toxo at: 2 at: 2.\n\t\n\tself assert: (oxo checkInDiagonals) equals: 'O'.",
"co... |
174 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInDiagonals2
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 1.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 3.
oxo at: 2 at: 2.
self assert: (oxo checkInDiagonals) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 7,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckInDiagonals2\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 1.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 3.\n\toxo at: 2 at: 2.\n\t\n\tself assert: (oxo",
"suffix": ".",
"completion": " check... |
175 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInDiagonals2
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 1.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 3.
oxo at: 2 at: 2.
self assert: (oxo checkInDiagonals) equals: 'O'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 3,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCheckInDiagonals2\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 1.\n\toxo at:",
"suffix": ".\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 3.\n\toxo at: 2 at: 2.\n\t\n\tself assert: (oxo checkInDiagonals) equals: 'O'.",
... |
176 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInRow
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 3 at: 2.
oxo at: 2 at: 3.
self assert: (oxo checkInRow: 1) equals: nil.
self assert: (oxo checkInRow: 2) equals: 'X'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 3,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCheckInRow\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at:",
"suffix": ".\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 3 at: 2.\n\toxo at: 2 at: 3.\n\t\n\tself assert: (oxo checkInRow: 1) equals... |
177 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInRow
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 3 at: 2.
oxo at: 2 at: 3.
self assert: (oxo checkInRow: 1) equals: nil.
self assert: (oxo checkInRow: 2) equals: 'X'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 6,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCheckInRow\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at:",
"suffix": ".\n\toxo at: 2 at: 3.\n\t\n\tself assert: (oxo checkInRow: 1) equals... |
178 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckInRow
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 3 at: 2.
oxo at: 2 at: 3.
self assert: (oxo checkInRow: 1) equals: nil.
self assert: (oxo checkInRow: 2) equals: 'X'. | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 7,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckInRow\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 3 at: 2.\n\toxo",
"suffix": ".\n\t\n\tself assert: (oxo checkInRow: 1) equals: ni... |
179 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckSet
| set |
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 2 at: 3.
set := ((oxo grid atColumn: 2) collect: [ :x | x state ]) asSet.
oxo checkSet: set.
self assert: oxo winner equals: nil.
set := ((oxo grid atColumn: 3) collect: [ ... | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 8,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckSet\n\n\t| set |\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 2 at: 3.\n\t\n\tset := ((oxo grid atColumn: 2) collect: [ :x | x state ]) ... |
180 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckSet
| set |
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 2 at: 3.
set := ((oxo grid atColumn: 2) collect: [ :x | x state ]) asSet.
oxo checkSet: set.
self assert: oxo winner equals: nil.
set := ((oxo grid atColumn: 3) collect: [ ... | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 4,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testCheckSet\n\n\t| set |\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at:",
"suffix": ".\n\toxo at: 2 at: 2.\n\toxo at: 2 at: 3.\n\t\n\tset := ((oxo grid atColumn: 2) collect: [ :x | x s... |
181 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testCheckSet
| set |
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 2 at: 3.
set := ((oxo grid atColumn: 2) collect: [ :x | x state ]) asSet.
oxo checkSet: set.
self assert: oxo winner equals: nil.
set := ((oxo grid atColumn: 3) collect: [ ... | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 6,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testCheckSet\n\n\t| set |\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo",
"suffix": ".\n\t\n\tset := ((oxo grid atColumn: 2) collect: [ :x | x state... |
182 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testFillWithCells
self assert: oxo grid size equals: 9 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testFillWithCells\n\n\tself assert: oxo grid",
"suffix": "",
"completion": " size equals: 9"
} |
183 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testGrid
self assert: (oxo grid isMemberOf: Array2D) | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testGrid\n\n\tself assert: (",
"suffix": "",
"completion": "oxo grid isMemberOf: Array2D)"
} |
184 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testInitialize
self
assert: oxo grid rowCount equals: 3;
assert: oxo grid columnCount equals: 3;
assert: oxo grid size equals: 9;
assert: oxo moves equals: 0 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "cascade",
"n_masked_tokens": 7,
"prefix": "testInitialize\n\n\tself\n\t\tassert: oxo grid rowCount equals: 3;\n\t\tassert: oxo grid columnCount equals: 3;\n\t\tassert: oxo grid size equals:",
"suffix": "",
"completion": " 9;\n\t\tassert: oxo moves equals: 0"
} |
185 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testIsOver
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 3 at: 2.
self assert: oxo isOver equals: false.
oxo at: 2 at: 3.
self assert: oxo isOver equals: true | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testIsOver\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo",
"suffix": ".\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 3 at: 2.\n\n\tself assert: oxo isOver equals: false.\n\t\n\toxo at: 2 at: 3.\n\t\n\... |
186 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testIsOver
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 3 at: 2.
self assert: oxo isOver equals: false.
oxo at: 2 at: 3.
self assert: oxo isOver equals: true | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testIsOver\n\n\toxo at: 1 at: 1.\n\toxo",
"suffix": ".\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 3 at: 2.\n\n\tself assert: oxo isOver equals: false.\n\t\n\toxo at: 2 at: 3.\n\t\n\... |
187 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testIsOver
oxo at: 1 at: 1.
oxo at: 2 at: 1.
oxo at: 3 at: 3.
oxo at: 1 at: 2.
oxo at: 1 at: 3.
oxo at: 2 at: 2.
oxo at: 3 at: 2.
self assert: oxo isOver equals: false.
oxo at: 2 at: 3.
self assert: oxo isOver equals: true | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 9,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testIsOver\n\n\toxo at: 1 at: 1.\n\toxo at: 2 at: 1.\n\toxo at: 3 at: 3.\n\toxo at: 1 at: 2.\n\toxo at: 1 at: 3.\n\toxo at: 2 at: 2.\n\toxo at: 3 at: 2.\n\n\tself assert: oxo isOver equals: false.\n\t\n\toxo at: 2 at: 3.\n\t\n\tsel... |
188 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testMoves
self assert: oxo moves equals: 0 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 5,
"prefix": "testMoves\n\n\tself",
"suffix": "",
"completion": " assert: oxo moves equals: 0"
} |
189 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testTurn
self assert: oxo turn equals: 'O'.
oxo at: 1 at: 1.
self assert: oxo turn equals: 'X' | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testTurn\n\n\tself assert: oxo",
"suffix": ".\n\toxo at: 1 at: 1.\n\tself assert: oxo turn equals: 'X'",
"completion": " turn equals: 'O'"
} |
190 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testTurn
self assert: oxo turn equals: 'O'.
oxo at: 1 at: 1.
self assert: oxo turn equals: 'X' | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 1,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "testTurn\n\n\tself assert: oxo turn equals: 'O'.\n\toxo at:",
"suffix": ".\n\tself assert: oxo turn equals: 'X'",
"completion": " 1 at: 1"
} |
191 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO-Tests/OXOGridTest.class.st | testTurn
self assert: oxo turn equals: 'O'.
oxo at: 1 at: 1.
self assert: oxo turn equals: 'X' | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 2,
"mask_type": "keyword_message",
"n_masked_tokens": 4,
"prefix": "testTurn\n\n\tself assert: oxo turn equals: 'O'.\n\toxo at: 1 at: 1.\n\tself assert:",
"suffix": "",
"completion": " oxo turn equals: 'X'"
} |
192 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOCell.class.st | at: row at: col
^ self new
row: row;
col: col | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 3,
"prefix": "at: row at: col\n\n\t^ self new\n\t\t row: row",
"suffix": "",
"completion": ";\n\t\t col: col"
} |
193 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOCell.class.st | col: anInteger
"Set cell's column during initialization."
col ifNil: [ col := anInteger ]
ifNotNil: [ self error: 'Tried to set cell''s column after initialization.' ] | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "col: anInteger\n\t\"Set cell's column during initialization.\"\n\n\tcol ifNil: [ col := anInteger ]\n\t\tifNotNil: [ self",
"suffix": "",
"completion": " error: 'Tried to set cell''s column after initialization.' ]"
} |
194 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOCell.class.st | printOn: aStream
"Print cell state for easier debugging process."
state
ifNil: [ aStream nextPutAll: '' ]
ifNotNil: [ aStream nextPutAll: state ] | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row: anInteger\n\t\"Set cell's row d... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 7,
"prefix": "printOn: aStream\n\t\"Print cell state for easier debugging process.\"\n\n\tstate\n\t\tifNil: [ aStream nextPutAll: ''",
"suffix": "",
"completion": " ]\n\t\tifNotNil: [ aStream nextPutAll: state ]"
} |
195 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOCell.class.st | row: anInteger
"Set cell's row during initialization."
row
ifNil: [ row := anInteger ]
ifNotNil: [ self error: 'Tried to set cell''s row after initialization.' ] | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row\n\t\"Get cell's row.\"\n\n\t^ ro... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 3,
"prefix": "row: anInteger\n\t\"Set cell's row during initialization.\"\n\n\trow\n\t\tifNil: [ row := anInteger ]\n\t\tifNotNil: [ self",
"suffix": "",
"completion": " error: 'Tried to set cell''s row after initialization.' ]"
} |
196 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOCell.class.st | state: aState
"Set cell state - restrict editing of a state once it's set."
^ state
ifNil: [ state := aState. true ]
ifNotNil: [ self error: 'Tried to edit cell''s state.'. false ] | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row\n\t\"Get cell's row.\"\n\n\t^ ro... | {
"fim_idx": 0,
"mask_type": "return",
"n_masked_tokens": 10,
"prefix": "state: aState\n\t\"Set cell state - restrict editing of a state once it's set.\"\n\n\t^ state\n\t\t ifNil: [ state := aState.",
"suffix": "",
"completion": " true ]\n\t\t ifNotNil: [ self error: 'Tried to edit cell''s state.'. false ... |
197 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOGrid.class.st | addMove
"Increment number of moves played."
moves := moves + 1 | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row\n\t\"Get cell's row.\"\n\n\t^ ro... | {
"fim_idx": 0,
"mask_type": "assignment",
"n_masked_tokens": 3,
"prefix": "addMove\n\t\"Increment number of moves played.\"\n\n\tmoves :=",
"suffix": "",
"completion": " moves + 1"
} |
198 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOGrid.class.st | at: row at: col
"Make move at said row and at said column if it's empty."
((self grid at: row at: col) state: self turn)
ifTrue: [ self addMove ] | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row\n\t\"Get cell's row.\"\n\n\t^ ro... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 10,
"prefix": "at: row at: col\n\t\"Make move at said row and at said column if it's empty.\"\n\n\t((self grid at: row at: col",
"suffix": "",
"completion": ") state: self turn)\n\t\tifTrue: [ self addMove ]"
} |
199 | https://github.com/matijakljajic/oxo-pharo | fe4bc55acb051acaba3102fe72af60a210bc2217 | src/OXO/OXOGrid.class.st | checkInCol: idx
"Check column on said index for a winner."
| set |
winner ifNil: [
set := ((self grid atColumn: idx) collect: [ :x | x state ]) asSet.
self checkSet: set ].
^ winner | [
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "Object subclass: #OXOCell\n\tinstanceVariableNames: 'row col state'\n\tclassVariableNames: ''\n\tpackage: 'OXO'"
},
{
"filepath": "repo_clone/oxo-pharo/src/OXO/OXOCell.class.st",
"code": "row\n\t\"Get cell's row.\"\n\n\t^ ro... | {
"fim_idx": 0,
"mask_type": "keyword_message",
"n_masked_tokens": 9,
"prefix": "checkInCol: idx\n\t\"Check column on said index for a winner.\"\n\n\t| set |\n\twinner ifNil: [\n\t\tset := ((self grid atColumn: idx) collect: [ :x | x",
"suffix": ".\n\t^ winner",
"completion": " state ]) asSet.\n\t\tself che... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.