<commit_before>import cobjects
from cobjects import CBuffer, CObject
import sixtracklib as st
from sixtracklib.tricub import TriCub, TriCubData
import pdb

if __name__ == '__main__':
    lattice = st.Elements()
    lattice.Drift(length=1.0)
    pset = st.ParticlesSet()
    pset.Particles(num_particles=100)

    job = st.TrackJob(lattice, pset)

    assert not job.has_stored_buffers
    assert job.num_stored_buffers == 0
    assert job.min_stored_buffer_id == 0
    assert job.max_stored_buffer_id == 0

    data_buffer = CBuffer()
    tricub_data = TriCubData(cbuffer=data_buffer, nx=100, ny=100, nz=100)
    assert data_buffer.n_objects == 1
    assert data_buffer.size > 0

    data_buffer_id = job.add_stored_buffer(cbuffer=data_buffer)
    assert data_buffer_id != st.stcommon.st_ARCH_ILLEGAL_BUFFER_ID.value<commit_msg>tests/python: remove pdb import in stored_buffer unit-test for python NS(TrackJob)s<commit_after>import cobjects
from cobjects import CBuffer, CObject
import sixtracklib as st
from sixtracklib.tricub import TriCub, TriCubData

if __name__ == '__main__':
    lattice = st.Elements()
    lattice.Drift(length=1.0)
    pset = st.ParticlesSet()
    pset.Particles(num_particles=100)

    job = st.TrackJob(lattice, pset)

    assert not job.has_stored_buffers
    assert job.num_stored_buffers == 0
    assert job.min_stored_buffer_id == 0
    assert job.max_stored_buffer_id == 0

    data_buffer = CBuffer()
    tricub_data = TriCubData(cbuffer=data_buffer, nx=100, ny=100, nz=100)
    assert data_buffer.n_objects == 1
    assert data_buffer.size > 0

    data_buffer_id = job.add_stored_buffer(cbuffer=data_buffer)
    assert data_buffer_id != st.stcommon.st_ARCH_ILLEGAL_BUFFER_ID.value
{'fraction_non_alphanumeric': 0.08571428571428572, 'fraction_numerical': 0.022157434402332362, 'mean_word_length': 4.39622641509434, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5929371', 'n_tokens_mistral': 649, 'n_tokens_neox': 620, 'n_words': 126}