Skip to content

Instantly share code, notes, and snippets.

View chintanparikh's full-sized avatar
🎯
Focusing

Chintan Parikh chintanparikh

🎯
Focusing
View GitHub Profile
package com.example.wheresmystuff.junits;
import android.test.AndroidTestCase;
import junit.framework.Assert;
import com.example.wheresmystuff.presenter.WheresMyStuff;
import com.example.wheresmystuff.model.*;
public class JUnitTestByChintan extends AndroidTestCase {
private User regular_user, admin_user;
lines = content.split("\n")
matches = []
non_matching_lines = lines.reject { |line| matches << line.scan(/[\n\r](.+):[\ \t]*(.+)/) }
matches.compact!
Template.items.items = function()
{
return Items.find({});
};
Template.new.events = {
'keyup #new-item': function (e) {
if (e.keyCode === 13)
{
var new_item = $("#new-item").val();
Template.new.events = {
'keyup #new-item': function (e) {
if (e === 13)
{
var new_item = $("#new-item").val();
Items.insert({name: new_item});
}
}
}
import java.util.Collection;
import java.util.List;
import java.util.ArrayList;
import java.util.Stack;
public class BST<T extends Comparable<T>> {
private Node<T> root;
private int size;
public enum Side { LEFT, RIGHT };
import static org.junit.Assert.*;
import org.junit.Test;
import org.junit.Ignore;
import org.junit.Before;
import java.util.ArrayList;
public class BSTTest {
private BST<Integer> tree;
import static org.junit.Assert.*;
import org.junit.Test;
import org.junit.Ignore;
import org.junit.Before;
import java.util.ArrayList;
public class BSTTest {
private BST<Integer> tree;
import static org.junit.Assert.*;
import org.junit.Test;
import org.junit.Ignore;
import org.junit.Before;
import java.util.ArrayList;
public class BSTTest {
private BST<Integer> tree;
import java.util.Collection;
import java.util.List;
public class BST<T extends Comparable<T>> {
private Node<T> root;
private int size;
public enum Side { LEFT, RIGHT };
import static org.junit.Assert.*;
import org.junit.Test;
import org.junit.Ignore;
import org.junit.Before;
import java.util.ArrayList;
public class BSTTest {
private BST<Integer> tree;