Program: 26834
Project: 26834
Buggy source:
public void testJoins(){
  Delete.tables(Company.class,Department.class);
  Company company=new Company();
  company.id=1;
  company.name="String_Node_Str";
  company.age=32;
  company.address="String_Node_Str";
  company.salary=20000.0;
  company.insert();
  company=new Company();
  company.id=2;
  company.name="String_Node_Str";
  company.age=25;
  company.address="String_Node_Str";
  company.salary=15000.0;
  company.insert();
  company=new Company();
  company.id=3;
  company.name="String_Node_Str";
  company.age=23;
  company.address="String_Node_Str";
  company.salary=20000.0;
  company.insert();
  company=new Company();
  company.id=4;
  company.name="String_Node_Str";
  company.age=25;
  company.address="String_Node_Str";
  company.salary=65000.0;
  company.insert();
  company=new Company();
  company.id=5;
  company.name="String_Node_Str";
  company.age=27;
  company.address="String_Node_Str";
  company.salary=85000.0;
  company.insert();
  company=new Company();
  company.id=6;
  company.name="String_Node_Str";
  company.age=22;
  company.address="String_Node_Str";
  company.salary=45000.0;
  company.insert();
  company=new Company();
  company.id=7;
  company.name="String_Node_Str";
  company.age=24;
  company.address="String_Node_Str";
  company.salary=10000.0;
  company.insert();
  assertEquals(SQLite.select(Method.count()).from(Company.class).count(),7);
  Department department=new Department();
  department.id=1;
  department.dept="String_Node_Str";
  department.emp_id=1;
  department.insert();
  department=new Department();
  department.id=2;
  department.dept="String_Node_Str";
  department.emp_id=2;
  department.insert();
  department=new Department();
  department.id=3;
  department.dept="String_Node_Str";
  department.emp_id=7;
  department.insert();
  assertEquals(SQLite.select(Method.count()).from(Department.class).count(),3);
  From<Company> joinQuery=SQLite.select(Department_Table.emp_id,Company_Table.name,Department_Table.dept).from(Company.class).join(Department.class,Join.JoinType.INNER).on(Company_Table.id.withTable().eq(Department_Table.emp_id.withTable()));
  String query=joinQuery.getQuery();
  assertEquals("String_Node_Str" + "String_Node_Str",query.trim());
  List<CompanyDepartmentJoin> companyDepartmentJoins=joinQuery.queryCustomList(CompanyDepartmentJoin.class);
  assertEquals(companyDepartmentJoins.size(),3);
  CompanyDepartmentJoin departmentJoin=companyDepartmentJoins.get(0);
  assertEquals(departmentJoin.dept,"String_Node_Str");
  assertEquals(departmentJoin.emp_id,1);
  assertEquals(departmentJoin.name,"String_Node_Str");
  departmentJoin=companyDepartmentJoins.get(1);
  assertEquals(departmentJoin.dept,"String_Node_Str");
  assertEquals(departmentJoin.emp_id,2);
  assertEquals(departmentJoin.name,"String_Node_Str");
  departmentJoin=companyDepartmentJoins.get(2);
  assertEquals(departmentJoin.dept,"String_Node_Str");
  assertEquals(departmentJoin.emp_id,7);
  assertEquals(departmentJoin.name,"String_Node_Str");
  Delete.tables(Company.class,Department.class);
}

Fixed version (ground truth):
public void testJoins(){
  Delete.tables(Company.class,Department.class);
  Company company=new Company();
  company.id=1;
  company.name="String_Node_Str";
  company.age=32;
  company.address="String_Node_Str";
  company.salary=20000.0;
  company.insert();
  company=new Company();
  company.id=2;
  company.name="String_Node_Str";
  company.age=25;
  company.address="String_Node_Str";
  company.salary=15000.0;
  company.insert();
  company=new Company();
  company.id=3;
  company.name="String_Node_Str";
  company.age=23;
  company.address="String_Node_Str";
  company.salary=20000.0;
  company.insert();
  company=new Company();
  company.id=4;
  company.name="String_Node_Str";
  company.age=25;
  company.address="String_Node_Str";
  company.salary=65000.0;
  company.insert();
  company=new Company();
  company.id=5;
  company.name="String_Node_Str";
  company.age=27;
  company.address="String_Node_Str";
  company.salary=85000.0;
  company.insert();
  company=new Company();
  company.id=6;
  company.name="String_Node_Str";
  company.age=22;
  company.address="String_Node_Str";
  company.salary=45000.0;
  company.insert();
  company=new Company();
  company.id=7;
  company.name="String_Node_Str";
  company.age=24;
  company.address="String_Node_Str";
  company.salary=10000.0;
  company.insert();
  assertEquals(SQLite.select(Method.count()).from(Company.class).count(),7);
  Department department=new Department();
  department.id=1;
  department.dept="String_Node_Str";
  department.emp_id=1;
  department.insert();
  department=new Department();
  department.id=2;
  department.dept="String_Node_Str";
  department.emp_id=2;
  department.insert();
  department=new Department();
  department.id=3;
  department.dept="String_Node_Str";
  department.emp_id=7;
  department.insert();
  assertEquals(SQLite.select(Method.count()).from(Department.class).count(),3);
  From<Company> joinQuery=SQLite.select(Department_Table.emp_id.withTable(),Company_Table.name,Department_Table.dept).from(Company.class).join(Department.class,Join.JoinType.INNER).on(Company_Table.id.withTable().eq(Department_Table.emp_id.withTable()));
  String query=joinQuery.getQuery();
  assertEquals("String_Node_Str" + "String_Node_Str",query.trim());
  List<CompanyDepartmentJoin> companyDepartmentJoins=joinQuery.queryCustomList(CompanyDepartmentJoin.class);
  assertEquals(companyDepartmentJoins.size(),3);
  CompanyDepartmentJoin departmentJoin=companyDepartmentJoins.get(0);
  assertEquals(departmentJoin.dept,"String_Node_Str");
  assertEquals(departmentJoin.emp_id,1);
  assertEquals(departmentJoin.name,"String_Node_Str");
  departmentJoin=companyDepartmentJoins.get(1);
  assertEquals(departmentJoin.dept,"String_Node_Str");
  assertEquals(departmentJoin.emp_id,2);
  assertEquals(departmentJoin.name,"String_Node_Str");
  departmentJoin=companyDepartmentJoins.get(2);
  assertEquals(departmentJoin.dept,"String_Node_Str");
  assertEquals(departmentJoin.emp_id,7);
  assertEquals(departmentJoin.name,"String_Node_Str");
  Delete.tables(Company.class,Department.class);
}