<commit_before>package pc;

import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import pc.config.PCConfig;

import static org.junit.Assert.*;

public class PCTest {

    @Test
    public void testPCCreationThroughApplicationContext() {
        ApplicationContext context =
                new AnnotationConfigApplicationContext(PCConfig.class);
        PC pc = context.getBean(PC.class);
        assertTrue(pc.isConnectedToTheInternet());
        assertTrue(pc.isMonitorWorking());
        assertTrue(pc.isKeyboardAndMousePluggedIn());
        assertTrue(pc.isPowerSupplied());
    }

    @Test
    public void testPCCreationThroughXMLContext() {
        ClassPathXmlApplicationContext context =
                new ClassPathXmlApplicationContext("pc.xml");
        PC pc = context.getBean(PC.class);
        assertTrue(!pc.isConnectedToTheInternet());
        assertTrue(!pc.isMonitorWorking());<commit_msg>Added new test case to reflect new config usage.<commit_after>package pc;

import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import pc.config.AllInOneConfig;
import pc.config.PCConfig;

import static org.junit.Assert.*;

public class PCTest {

    @Test
    public void testPCCreationThroughAllInOneJavaConfig() {
        ApplicationContext context =
                new AnnotationConfigApplicationContext(AllInOneConfig.class);
        PC pc = context.getBean(PC.class);
        assertTrue(pc.isConnectedToTheInternet());
        assertTrue(pc.isMonitorWorking());
        assertTrue(pc.isKeyboardAndMousePluggedIn());
        assertTrue(pc.isPowerSupplied());
    }

    @Test
    public void testPCCreationThroughModularJavaConfig() {
        ApplicationContext context =
                new AnnotationConfigApplicationContext(PCConfig.class);
        PC pc = context.getBean(PC.class);
        assertTrue(pc.isConnectedToTheInternet());
        assertTrue(pc.isMonitorWorking());
        assertTrue(pc.isKeyboardAndMousePluggedIn());
        assertTrue(pc.isPowerSupplied());
    }

    @Test
    public void testPCCreationThroughXMLConfig() {
        ClassPathXmlApplicationContext context =
                new ClassPathXmlApplicationContext("pc.xml");
        PC pc = context.getBean(PC.class);
        assertTrue(!pc.isConnectedToTheInternet());
        assertTrue(!pc.isMonitorWorking());
{'fraction_non_alphanumeric': 0.0920314253647587, 'fraction_numerical': 0.0, 'mean_word_length': 3.8007181328545783, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, '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': '1181527', 'n_tokens_mistral': 691, 'n_tokens_neox': 684, 'n_words': 116}