import { DEFAULT_BOOTSTRAP } from './default-bootstrap.const';

describe('DEFAULT_BOOTSTRAP', () => {
  it('is marked unpublished', () => {
    expect(DEFAULT_BOOTSTRAP.published).toBe(false);
  });

  it('has every feature flag turned on', () => {
    Object.values(DEFAULT_BOOTSTRAP.featureFlags).forEach(value => {
      expect(value).toBe(true);
    });
  });

  it('has every optional MarketplaceFeaturesConfig flag turned on', () => {
    expect(DEFAULT_BOOTSTRAP.features).toBeDefined();
    Object.values(DEFAULT_BOOTSTRAP.features!).forEach(value => {
      expect(value).toBe(true);
    });
  });

  it('has at least one page with a hero section', () => {
    expect(DEFAULT_BOOTSTRAP.pages.length).toBeGreaterThan(0);
    const heroSection = DEFAULT_BOOTSTRAP.pages[0].sections.find(s => s.type === 'hero');
    expect(heroSection).toBeDefined();
  });

  it('has a generic brand name, not a real tenant name', () => {
    expect(DEFAULT_BOOTSTRAP.branding.brandName).toBe('Marketplace');
  });
});
