def _in_cis(chrom, pos, gene_id, tss_dict, window=1000000):
    """Test if a variant-gene pair is in cis"""
    if chrom == tss_dict[gene_id]['chr']:
        tss = tss_dict[gene_id]['tss']
        if pos >= tss - window and pos <= tss + window:
            return True
        else:
            return False
    else:
        return False
