-
Notifications
You must be signed in to change notification settings - Fork 379
[Nexthop][fboss2-dev] Rewrite fboss2-dev CLI end-to-end tests in C++ with gtest #893
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
benoit-nexthop
wants to merge
15
commits into
facebook:main
Choose a base branch
from
nexthop-ai:fboss2-cli-prototype_part25
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+8,900
−1,077
Open
Changes from all commits
Commits
Show all changes
15 commits
Select commit
Hold shift + click to select a range
0f56ea6
Add buffer-pool configuration support
manoharan-nexthop c64dd21
Add a `fboss2 config interface <name> switchport access vlan <N>` com…
benoit-nexthop 2ce7e5f
Add a unit tests checking the CLI command tree.
benoit-nexthop 31eb904
Save the config commands to CLI metadata and in session commit.
benoit-nexthop af5398a
Replace file-based config versioning with Git
benoit-nexthop e91d0a0
Add `config session rebase` command for concurrent session conflict r…
benoit-nexthop c5e8e1b
Add CLI command for managing static MAC entries on VLANs
manoharan-nexthop 73d5198
NOS-4057: Add show running-config CLI command (#382)
benoit-nexthop a46a1d0
Add CLI commands for configuring priority group policies
benoit-nexthop 3a00aa1
Add CLI commands for configuring per-port PFC settings
benoit-nexthop 79c607d
Add CLI commands for configuring port queue configs (queuing-policy)
benoit-nexthop 7be0a14
Add active-queue-management (AQM) support to queuing-policy queue-id CLI
benoit-nexthop 28c0edc
Add config interface queuing-policy CLI command
benoit-nexthop b040a70
Add QoS policy map configuration commands
benoit-nexthop de18a53
Rewrite fboss2-dev CLI end-to-end tests in C++ with gtest
benoit-nexthop File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| /* | ||
| * Copyright (c) 2004-present, Facebook, Inc. | ||
| * All rights reserved. | ||
| * | ||
| * This source code is licensed under the BSD-style license found in the | ||
| * LICENSE file in the root directory of this source tree. An additional grant | ||
| * of patent rights can be found in the PATENTS file in the same directory. | ||
| * | ||
| */ | ||
| #pragma once | ||
|
|
||
| #include <CLI/App.hpp> | ||
| #include "fboss/cli/fboss2/CmdGlobalOptions.h" | ||
| #include "fboss/cli/fboss2/CmdList.h" | ||
| #include "fboss/cli/fboss2/CmdSubcommands.h" | ||
|
|
||
| namespace facebook::fboss::utils { | ||
|
|
||
| /** | ||
| * Initialize the CLI app with global options and command tree. | ||
| * This sets up the CLI infrastructure and should be called before parsing. | ||
| * | ||
| * This function is shared between the main CLI binary and CLI E2E tests | ||
| * to ensure consistent CLI initialization. | ||
| */ | ||
| inline void initApp(CLI::App& app) { | ||
| app.require_subcommand(); | ||
|
|
||
| // Initialize global options (--fmt, --host, etc.) | ||
| CmdGlobalOptions::getInstance()->init(app); | ||
|
|
||
| // Initialize command tree with all available commands | ||
| CmdSubcommands::getInstance()->init( | ||
| app, kCommandTree(), kAdditionalCommandTree(), kSpecialCommands()); | ||
| } | ||
|
|
||
| } // namespace facebook::fboss::utils |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why suddenly includes so many libraries? Your change in the implementation below doesn't seem to rely on all these libraries